I don’t know where this ‘intellectual’ preoccupation of viewing past norms critically, through modern lenses, started, but we see are seeing it everywhere in modernity. You have to try to view social norms of the past through the context of past economics and culture.
First of all: No birth control at all > often too many mouths to feed in the home. Once the labor needs of the farm were met, sons were sent at early ages to the navy, army, or to labor in factories and sweatshops. This reduced the economic burden in overpopulated homes. Similarly, pretty daughters who were virgins could be wed to well established, older men, strengthening the household economy or estate by advantageous marital unions. Homely daughters might be married, too, but the bride usually had to pay a dowry to her new husband.
So, there was an incentive in past society to marry off younger women. Many of these parameters have disappeared or changed, so the socially acceptable age for marriage has risen.
Marriage served an important political function (as among the aristocrats of Europe) in extending and unifying important families, empires, nations, or kingdoms. These considerations may have outweighed the nuptial (mating) concerns in some circumstances. The Church as arbiter of marriage, would have had Canon law compatible with the prevailing requirements of states in such matters.
Mohammed supposedly had 13 wives. He betrothed his last wife, Aisha, at age 6 or 7, but did not marry her until age 9. Supposedly “in his mercy” consummation of the marriage took place later, at age 11 or 12.
It is absurd to judge antiquity through modern lenses.
What does it change? Those times are long gone. The modern Church is not responsible for ancient Canon law.
P.S.: The consent to marry was largely PARENTAL…not “informed consent” of the bride. Young women were a household commodity belonging to the parents. Must have been a lot of elopements!