The Hogwarts Express is not really a steam train. It does look like one and it acts like one in certain key ways, but it isn’t one. It’s a magical device. It borrows its form and its intended function from real steam trains, but not the technology. It’s like the Ministry cars, the Knight Bus, and Wizard’s Wireless, which also borrow their form from Muggle technology but which are magical devices.
Wizarding “machines” aren’t Muggle machines. They don’t work on petrol or coal or electricity, they work by magic. In some cases, such as the Hogwarts Express, they are copied from Muggle machinery (and in this case it’s clearly a copy of a Muggle device, since many parts of it would have no function in the wizarding version, but there they are, clearly copied from the Muggle original without an understanding of what those parts were for). The Hogwarts Express, powered by magic, goes where it’s supposed to because that’s what it’s supposed to do. Magic is more than anything else intention made reality. The Hogwarts Express chugs away up north because it is magicked to do so.
So what about the track? Someone on the HP4GU list some time ago came up with a perfect and wonderful solution: the Hogwarts Express uses existing track for most of the journey, but just squeezes past the other trains on the line or cars at the crossings. It follows the same pattern as the other magical transportation devices we’ve seen, the Knight Bus and the Ministry cars, and just somehow manages to jump/squeeze/slip through. It’s not heard or seen by Muggles because, as Stan Shunpike points out, “[t]hey never notice nuffink, they don'” (PA3).
The driver and the guard and the witch with the cart are the equivalent of Ernie Prang and Stan Shunpike: trained to operate magical devices using magic without really understanding the technology from which their devices are copied. Ernie shifts the wheel back and forth but doesn’t really steer the bus along the road specifically, he’s making the magic work. One turn could send them to the left side of the motorway or halfway to Torquay, depending on what he intended it to do.
The train itself looks like a train from the outside and pretty much looks like a train on the inside, although I think it’s likely that it adjusts its interior dimensions for the task at hand (there is always one more compartment, but never an extra, it seems). Unlike the Knight Bus, which looks fairly similar to a bus on the outside but nothing like a bus on the inside, the Hogwarts Express seems to be to most appearances a real train. But it isn’t. It’s magic.