Because John was immersing Jews in symbol of their repentance over sin against the Law. As a close relative, John must have known that Jesus was righteous and therefore in no need of repentance.
فِي ٱلْبِدَايَةِ ،‏ أَرَادَ يُوحَنَّا ٱلْمُعَمِّدُ أَنْ يَمْنَعَ يَسُوعَ مِنَ ٱلْمَعْمُودِيَّةِ .‏