So platinum is a transition metal. In general transition metals are reducers, which means they can give the electrons they have, to the sodium atoms. Also in chemistry we look at sub orbitals rather that shells(2,8,8). So due to the energy from heat, the d orbital split as electrons move to a higher energy level. Some of the electrons are given to the sodium ions and therefore the flame changes colour to yellow.
The excitation of the electrons is caused by them getting energy and so moving up an energy level. This energy is released and the electron returns to it's original state. The energy released, however, does not release in the same direction, but in different/various directions. Therefore the colour of the light changes as some energy is released in the surrounding.
Since water molecules are polar. Unequal sharing of electrons between the elements that make it. The hydrogen atoms would experience a slight partial positive charge as the electron density is more close to the oxygen atom making it partially negative.