This isn't the only time Jesus goes off to be by Himself in the Gospels, the most notable time being in the Garden of Gethsemane. My theory is that Jesus is actually an introvert. That is, Jesus seems to need to recharge by Himself.
It might seem strange to think of Jesus as an introvert. He has a message to give to many people after all. But being an introvert can be a huge help when working with people. An introvert will natural understand, without having to learn over time, that you can't force your way into people's hearts. You have to coax your way in. You have to develop a relationship with people before they will let you in, and relationship is what God is all about.
Incidentally, I believe this is also why God seems to have a preference for choosing introverts for ministry.
By going off on His own, Jesus also is giving an example to us. We all need to go and spend time alone with God from time to time, whether we are extroverts or introverts. Jesus is showing us the path forward to be able to better love both God and our neighbor, and He's showing us this through His very being.