Pure water does not conduct electricity. Any impurities, like salts, in the water enable it to conduct electricity. When salts are dissolved in water, they separate into different electrically charged atoms called ions. Salt, or sodium chloride (NaCl), breaks up into positive Na ions and negative Cl ions.
If you place a battery with a negative pole and a positive pole into water, the negative ions will be attracted to the positive pole and the positive ions will be attracted to the negative pole thus creating a closed circuit.