There is in fact oxygen in water. Water is made up of 2 hydrogen molecules and 1 oxygen molecule. In addition to this oxygen and other gasses dissolve in water, however our lungs are unable to use this oxygen as there is so much less in water than in the air. The oxygen that fish breathe is not the oxygen in H2O. Instead, the fish are breathing O2 (oxygen gas) that is dissolved in the water. Fish are able to breathe the dissolved oxygen out of the water using their gills. The main reason why gills work for fish is the fact that fish are cold-blooded, which reduces their oxygen demands. Warm-blooded animals like whales breath air like people do because it would be hard to extract enough oxygen using gills for the amount that they and we need.
Humans cannot breathe underwater because our lungs do not have enough surface area to absorb enough oxygen from water, and the lining in our lungs is adapted to handle air rather than water.