Transport is something we take for granted these days. If you live in a western/rich nation private vehicle ownership is something most of us take for granted. But there was a time when private transport meant owning a horse, or of you were very well off a horse and carriage. D&D campaigns tend to be set in a roughly medieval setting and that definitely puts such modes of transport into the hands of the privileged few... including the PC's. For most people personal transport meant walking.
Of course D&D being an inherently magical setting means that transport does not have to be limited to historically accurate vehicles like Horses, Carriages, Ships etc. In my last campaign I provided the players with a way of crossing the vast deserts of the abyss which was inspired by the famous Sailing Stones of Death Valley. I scaled up the concept into gigantic boulders that could be navigated across the desert by thought alone.
Other fantastical transport ideas include things like Portals, magically powered airships and flying beasts such as the Eagles from the Lord of the Rings. Sometimes making a journey by foot can be a necessary part of the story, but other times its important to keep the story moving along swiftly. The long walk may be accompanied by encounters and adventure but now and again it may just be worth giving your players another way to get where they are going.