What happens? She shows him the ropes, I assume.
If you want to know if they CAN get married: It depends on the country you're in (or in the U.S., on the state you're in).
In the U.S., marriage laws are made by the state governments, not the national government. And they can be written in lots of different ways. Lots of them put the minimum age for no-questions-asked marriages at 18 (only Mississippi and Puerto Rico require 21 - not that PR is a state). But when you get into the questions-asked-and-answered marriages, some states allow parents or judges to authorize marriages at much lower ages, down to 14. 18 states have NO minimum age written into their law, and some states explicitly give judges the authority to grant marriage licenses at any age they see fit.
So, if you're in the U.S., you've got to know your state law.
As far as I've been able to find, there is NO state in which a virgin (even a 40 yr old one) is forbidden to marry.