All the prior answers miss an important point that is glossed over in the film, where the hole in the rover actually makes no sense.
In the book of the film, Mark faces the challenge of fitting three large life-support elements from the Hab into a rover.
What the film adaptation changes is that, in the book, Mark uses two rovers for the trip to Ares 4’s landing site.

(The film’s rover, with the unnecessary balloon and an unpressurized trailer. How does that pressurized balloon stay inflated while the rover door’s open, anyway?)
Probably to save production time and prop costs, we see in the film that Mark has two rovers, but the second is wrecked by the storm, so he scavenges what he could use from it and we never see this second rover again. Budget-wise, we likely see the same rover, with two identities.
In the book, Rover 2 is his primary transport. Early on, he strips the second rover (Rover 1) of its battery to use for his trip to retrieve the old Pathfinder probe.
After getting communication with NASA, they provide him plans to get the life-support equipment into a rover. The problem in the book was that one of the three components was too large to fit in the rover. To make it fit, a hole was needed to be cut in a rover top.
Rather than cutting into Rover 2, Mark cut into the rooftop of Rover 1 to allow the needed items to fit. He also made a series of ingenious improvisations to condense what was required for the long trip to the Ares 4 MAV spacecraft to fit in Rover 1, which becomes the actual trailer in the book.
In the film, what suspenseful story was made of Rover 1 was condensed down to a unpressurized trailer, complete with a powered crane that the book’s Mark wished he had in getting Pathfinder and other heavy objects moved about, which strained his back considerably.
So, in the film, there was no reason for Mark to cut into the roof of his sole rover. All of the big stuff fit on that unpressurized, open-air trailer that didn’t exist in the book.
This wasn’t the only thing that didn’t make sense in the film adaptation that’s related to the hole.
Remember the famous and funny “space pirate” lines?
I’ve been thinking about laws on Mars. There’s an international treaty saying that no country can lay claim to anything that’s not on Earth. By another treaty if you’re not in any country’s territory, maritime law applies. So Mars is international waters. Now, NASA is an American non-military organization, it owns the Hab. But the second I walk outside I’m in international waters. So Here’s the cool part. I’m about to leave for the Schiaparelli Crater where I’m going to commandeer the Ares IV lander. Nobody explicitly gave me permission to do this, and they can’t until I’m on board the Ares IV. So I’m going to be taking a craft over in international waters without permission, which by definition… makes me a pirate. Mark Watney: Space Pirate.
The problem for the film is that Mark says, “No one expressly gave [him] permission to [use the MAV]”. But in the film, Mark still maintains communication with NASA throughout the remainder of the story, taking Pathfinder with him.
The space pirate line makes more sense in the book because an electrical short-circuit accident, caused by a drill used in making the Rover 1 holes, destroys Pathfinder, leaving Mark cut off from Earth once more (with no explicit permission to board the MAV) until he’s able to reach the Ares 4 MAV.
