Hegel didn't think family relationships should be viewed as essentially contractual (that is part of what makes them family, rather than civil-law or financial relationships) and conversely, he didn't think property-rights and contract-rights could coherently extend to encompass non-economic parts of someone's life.
(For example, you can tell someone you're going to believe a certain dogma, or that you're going to vote for a certain party in the elections, but per Hegel it's not really coherent to talk about entering into a contract to believe or to vote because the underlying logic that makes contracts about property normatively binding doesn't extend to property. In fact - iirc - Hegel even has a fairly circumscribed conception of employment contracts in that if the employee just doesn't show up he thinks the employer might be abled to sue to financial damages but has no ethical right, in general, to force the employee to do the job he agreed to. Again this differs from Kant: in Met. der Sitten Kant says explicitly than an employment contract entitles the master to fetch back a runaway servant, beat him, and generally do whatever is necessary to get him to do the job he agreed to do.)
You can understand it this way: the components of Kant's definition of marriage sound pretty darn similar to the definition of legal prostitution. The difference is that Kant says you make the contract perpetual (like a contract for sexual slavery or concubinage) and then make it reciprocal (so both parties are the concubine of the other). In other words, what Kant thinks is wrong about the prostitution-contract is that it's one-sided – one party is using the other (sexually), and you can fix that if both parties are treating the other the way they would like to be treated. Hegel doesn't agree with that one-size-fits-all definition of what makes an action unethical, nor does he agree that anything at all that two people both agree to becomes obligatory (he stresses that this is a favorite argument for those who serially manipulate, exploit, and abandon other people...), so naturally he has a different account of marriage.