The short of it.
There is a condition called
plrunderwater (plrunderwater=1). Used in conjunction with a timer you can time how long the player is under water. Without oxygen (re: body armor script mentioned by raymondlee306) you can reduce the player's health by so much in timed increments and if the player doesn't come up for air, eventually he/she runs out of oxygen (health) and dies.
Addendum:
There is also a condition command for entities. This command would be placed in the entity's main script. It is called
underwater. You can check to see if an entity goes under water if the water level is rising. If you use underwater=1 and the entity is under water then it returns true and whatever actions you want to do will be performed.
Terry