What was the reason of Jesus' baptism?
In this, as in many things connected with the earthly life of our Lord, there is much that is mysterious, and we can never hope here to solve these difficulties with any completeness.
Bishop Wordsworth sums them up well in his words: "He came to baptize water, by being baptized in it."
Ignatius ('Ad. Eph.,' 18, beginning of the second century) writes, "He was baptized that, by his submission to the rite, he might purify the water."
Jerome, in the same strain, says, "He did not so much get cleansing from baptism, as impart cleansing to it."
It would seem that Jesus, in submitting to the rite himself, did it with the intention of sanctifying the blessed sacrament in the future.
[Excerpt from the Pulpit Commentary]