In science there is a priciple known as the principle of emerging properties. This principle holds that upon increasing the level of complexity of an objects, the whole gains new properties which is not present in the sum of its parts.
For example, in math, consider systems of differential equations. A one dimensional system exhibits very simple behavior with trajectories either extending to infinity or approaching a fixed value. Two dimensional systems can exhibit oscillations and contain periodic orbits, which are impossible in a one dimensional system. Three dimensional systemc can exhibit chaotic behavior which does not occur in two dimensional systems.
Similarly in chemistry, molecules have properties which are different from the atoms which compose the molecules. For example, whereas an atom cannot have a permanent dipole, a molecule can posses a permanent dipole. This allows a wider variety of interactions between molecules than between atoms. This helps account for why hydrogen and oxygen are gaseous at room temperature and why water is liquid at room temperature; water's permanent dipole allows strong intermolecular interactions than hydrogen or oxygen. Other emergent properties help make water significantly different than its component atoms.
Furthermore, you are incorrect when you say that electrons and protons don't change their physical states. The electrons in water are in different quantum states than in oxygen or hydrogen atoms. Instead of filling atomic orbitals, they are now contained in molecular orbitals of different energies and symmetries. The difference is easy to see:
atomic orbitals of hydrogenhttp://winter.group.shef.ac.uk/orbitron/AOs/1s/index.html
atomic orbitals of oxygenhttp://winter.group.shef.ac.uk/orbitron/AOs/1s/index.htmlhttp://winter.group.shef.ac.uk/orbitron/AOs/2s/index.htmlhttp://winter.group.shef.ac.uk/orbitron/AOs/2p/index.html
molecular orbitals of water: http://www.lsbu.ac.uk/water/h2oorb.html