I can understand completely why it was 12 to begin with. That's the average age of the onset of human puberty, which biologically, makes one fertile and therefore as developed as one needs to be to no longer be considered a child.
I can also understand why it was changed to 18, which is (in some places) the age at which humans are said to be mentally developed enough to be fully responsible for their own actions, and as far as their thinking and emotional life is concerned, no longer a child.
If the cutoff point didn't affect the mechanics of the game, it wouldn't matter enough to include it in the raws in the first place, but it does. A child can't be assigned work, can't fight in the military, and can't produce offspring. For each of these 3 effects, it is fully possible for societies to consider a pubescent between the ages of 12 and 18 adult enough to engage in these activities (and you can easily find examples of places where they do, even in 2022). But, here in the US where the game is being made we've decided it's more wise to consider pubescents as not adult until they are 18. So, just guessing here, the Adams brothers decided to force the dwarves to be more American. Maybe they were worried that people would think they were making a statement about the age of consent, which it isn't, but I can understand why they'd be fearful of that.
And honestly, they are dwarves, not humans, so the cutoff could be anything from 6 to 60 and still be justifiable. But as far as gameplay goes, increasing childhood by 50% makes the game less fun, IMO. Just for fun, I increased elves to 26 because I want them to suffer