Baby teeth, also known as milk teeth or deciduous teeth, start forming in the jaws of a baby in utero with the front teeth almost fully formed (apart from the roots) by the time of birth. Baby teeth erupt from about 6 months starting with the front teeth and are usually all present by the age of two and a half years. The first permanent grinding tooth (molar) erupts just behind the last baby molar. Then the front baby teeth get slowly replaced with permanent teeth and by about 12 years of age all the permanent teeth are erupted in the mouth and by adulthood most people have their 3rd molars (“wisdom teeth”).
The jaws of infants and children are far too small to accommodate the larger permanent teeth. Baby teeth are essential for the development of the mouth. They maintain the jaw length, and provide guides for the eruption pathway and therefore proper placement of permanent teeth.
Humans aren’t the only species who have two sets of teeth, but not all animals who have teeth have two sets. Some animals, such as hamsters and moles, only have one set of teeth in their lifetime. Most other vertebrates such as reptiles and fishes have the ability to replace their teeth over and over again. The tooth sizes are very similar and non-specialised.
So, really, the question is why do we only have one set of baby teeth and permanent teeth!
Mammals have very specialised sets of teeth that need to fit together properly to work well. Each tooth has a specific function and they need to work together as a unit, which makes chewing much more efficient for the purposes of getting nutrients from food. If they are constantly being shed and replaced throughout life the precision matching of shape and size of neighbouring teeth that enable that efficient chewing is lost.
But there is a trade off with developing such specialised teeth – it takes more energy to make them, so we are left with one set of teeth during development and one throughout our whole adulthood.