You may have noticed ice floating on water. Density of an object is defined as the mass of an object per unit volume at some definite temperature. Density should not be confused to the quantity of substance present. The density of a gold coin and a gold statue could be the same though the statue may contain greater amount of gold. Thus density is independent of the quantity present.
Any substance that is less dense than water floats on water. When the substance is denser, it sinks to the bottom of the water. While it sinks, it displaces an amount of water equal to its weight. Normally substances are most dense in their solid state than in their liquid state. Water is an exception in this case as it is denser in liquid state compared to its frozen solid state called ‘ice’.
When a liquid freezes into a solid, the liquid particles move closer together and form strong bonds with one another. There are now more particles in the same area causing the frozen solid to be denser than the liquid. The reason for frozen solid ‘ice’ being less dense than water is because of the hydrogen bond present in water molecule.
Water molecule contains two hydrogen atoms are covalently bonded to one oxygen atom and also has an additional attraction to the neighboring oxygen atom of another water molecule. This bond with the neighboring oxygen atom is called the hydrogen bond. Hydrogen bonds are very specific and can lead to special properties in certain molecules. Hydrogen becomes slightly positive repels other hydrogen atoms and attracts negatively charged oxygen atoms.