John the Baptist was preaching in the wilderness of Judea and telling the people, “Repent, for the kingdom of heaven is at hand.” (ESV)
John the Baptist also told them he was the one the prophet Isaiah proclaimed would come before Jesus Christ. “The voice of one crying in the wilderness: Prepare the way of the Lord; make his paths straight.” (ESV)
Matthew described the clothing worn by John the Baptist. His garment was made of camel hair and his belt was made of leather. What purpose would Matthew have for giving us this information? It seems a bit trivial.
There is a description of the prophet Elijah in 2 Kings 1:8: “He wore a garment of hair, with a belt of leather about his waist.” (ESV)
Also, in Zechariah 13:4, we learn it was common for prophets to wear a clock made of hair.
It seems Matthew was comparing John the Baptist to Elijah and wanted his audience to know John the Baptist was a prophet.