Fathers have every right to raise their own children, regardless of their marital status.
A father’s right to raise his own child is not contingent upon his marital status.
And it is quite possible that:
A) the mother doesn’t want to be involved with raising the child
B) the mother doesn’t want to be married
Then don't knock her up, sinple.