Egg white is mainly water and a protein called albumen. Albumen molecules are fairly long and nearly straight. That means that they slip past each other easily and so the mixture behaves like a liquid. As you should know, heat denatures proteins - it causes them to twist into new shapes. These twisted shapes get entagled with each other and can no longer slide past each other. In other words it behaves like a solid. The heating may also allow parts of neighbouring molecules to come into contact where bonding can occur.