How is water heavier than petrol, even though its molecular weight is less than petrol?

Density relates to the mass per unit volume. If your molecules are heavier but take up more space, the net result could be more or less mass per unit volume.

When you look at a typical hydrocarbon, it has a lot of carbon and hydrogen. Now atom for atom, oxygen is heavier than carbon (ignoring isotopic abundance, roughly a 16:12 ratio). So if the molecules were otherwise the same shape, if we replaced the carbons with oxygens the hydrocarbon would become heavier (you can’t do that of course - the chemistry is different).

But the larger and more complex shape of the hydrocarbon molecules has another effect. Imagine two elevators. In one elevator we cram a squad of ballet dancers - tall, elegant, and able to be packed very closely. In the other elevator there are a number of people who just went shopping - they carry big bags and generally take a lot of space. It’s quite possible you could get 15 ballet dancers into the first elevator and only five shoppers in the second. So though the dancers might weigh 100 pounds each and the shoppers 200 pounds, the first elevator car will be heavier.

The same analogy can help explain why density of most materials goes down when temperature goes up. Imagine the dancers hear music and start to dance. Suddenly 15 of them aren’t going to fit in that elevator!

Maybe that’s why elevator music is usually so awful?

Because water molecules are small and pack tightly together, causing water to have a greater density than petrol.

One of my Chemistry teachers had an interesting way to describe this type of phenomenon.
Because the water molecule is shaped like a triangle, it is possible for the water molecules to "snuggle up" with each other, and pack themselves close together. Like this:
He claimed that Water molecules behave more like H(100) O(50) that H(2) O.
Now, I'm sure we could think of a dozen reasons why this isn't correct, but: this does show a unique property of water. It relates closely to the answers provided by @Floris and @G. Smith.

If water really were H(100) O(50), would that explain the property of your original question? I believe it would.