They occur when a fuel truck jack-knifes which is when the truck's front part folds/skids usually on a slippery surface and in some cases the truck falls.
The company that is delivering the gasoline should clean up the mess because they own the production of the gas, and should be responsible if a problem occurs.
Exxon a gasoline production company had an oil spill and had to pay $2.1 billion for cleanup costs, economic damages were approximately $500-600 million and were paid to private parties, and punitive damages being $500 million, this is close to what most of the costs would be in the situation.
They clean up the spill by using pumper truck's to pump out the fuel and dig out ditches to remove soil that has fuel in it, they have to quickly contain so the oil/gas doesn't spread to lakes and kill and poison the fish, another way to clean it up is to spread sand on the roadway to control the slipperiness.