Water is a chemical, like almost everything, but it has the chemical formula H2O.
When we draw the compound it looks something like:
O -- H
When water is "electolyzed" (electricity is applied, with appropriate voltage used) you can split water into the two elements that make it, hydrogen and oxygen. For every one water molecule, you will make 2H atoms, and one O atom, however, neither oxygen nor hydrogen exist like that, they much prefer to exist as H2 gas and O2 ...
What happens to change water treated with a battery and washing soda to change into two gases are discussed.