Milk contains surfactants (primarily lipids), which allow stable bubbles to form. In intense boiling, these bubbles can become mixed with liquid, supporting the liquid above them and forming what I'll call for want of a better term a "wet froth." Imagine a bunch of sponges made out of liquid. They take up more space than they would if you compressed them down and forced out the air. The inclusion of the water vapor in the bubbles lowers the density of the mixture, causing it to expand and overflow the pot.