Rules do exist—very detailed rules. Actually, it's the IMDG code. It's put out through the IMO. Canada subscribes to that document.
It's called the “International Maritime Dangerous Goods Code”. It documents every single hazardous substance with a UN number, and then has specific stowage requirements for that cargo as it relates to the quantity, how it is to be packaged, what it is allowed to be stored against or not allowed to be stored adjacent to and all of the relative positions as to where it should be in a ship.