Jesus is the last OldTestament prophet. So, He was compelled to keep all the Law which demanded purification, and baptism was the rite that symbolically purified.