Custody battle? (California)

So my friend is pregnant with her second child. She wants the baby to have her last name but she may run into some problems. She was talking to this guy and found out he was lying about being single. It turned out he was still with his girlfriend he claimed he broke up with and didn't want either of them to know about each other. She wanted to be with him but told him she wouldn't be with him if he was still with another girl, he again pretended he left her and she found out through Facebook they were still together and he was lying again so she just ditched him. Anyway she ended up finding out she got pregnant and she told him he was going to be a father. He read her message and blocked her. She assumed that meant he wanted nothing to do with her or the baby so left it at that because she had no way to contact him. This morning he called her and since she was asleep and didn't answer he left her a voicemail saying "Hey it's _____ I know I haven't called you in a long time but anytime you get a blocked number calling you it's me. Alright bye." 
So now she has to play the waiting game until he calls again to see why he called since his number is blocked and she's worried he's going to either A) hurt her again B) try and take the baby from her C) make her "share" the baby with him and his girlfriend (assuming he still hasn't left the other woman) or D) be in jail again 
Questions are: Does she have to give the baby the dad's last name?/If she tries to or manages to give the baby her last name, can he take her to court to change the baby's name to his name?
We live in Calirfornia I'm not sure how all this works and I would like to help her if I can.

Vote below to see results!