To become a knight took many years of training. Even after completing this training, not all became knights.
Page (young servant)
If a boy was to become a knight, at around 7 years old he was sent to work as a page in the noble household of the Liege Lord (subject owing allegiance to a feudal sovereign). There he worked as a page for around 7 years.
During this time the page would follow a strict code of conduct. He became a servant to a knight and would be responsible for dressing the knight, cleaning clothes and weapons and waiting at table. He may also have been used as a messenger.
In return he received food and lodgings, education and learnt the basics of combat. He became an apprentice squire.
At around 14 years of age a page moved on to be a squire. A squire was assigned to work with a specific knight for the completion of his training. He became a servant and an apprentice to the knight. He also became a teacher to the next page.
A squire trained with a knight and went into battle with the knight. A squire needed to prove that he had the ability to become a knight.
A squires tasks included; saddling the horse, caring for armour and weapons, being a shield or armour bearer and maybe even carrying the knights flag into battle.
Not every squire became a knight but if they did it would be at around the age of 21.