A 23-year-old man has been charged with murder after a newborn baby died in hospital following an incident in Perth's north.