Fathers Rights: Not Married?

So I am currently expecting my first child with my boyfriend and we have gotten into many fights about last name and plethora of other things.

He is threatening I will be alone in the hospital if I do not change my mind and give baby his last name. So I was wondering.. if we aren’t married does he legally have any rights or say so at all?

I don’t know how the paperwork or the law works really, but does he have any say/rights in this matter? TIA.