Why is water plentiful in the desert?

Water is scarce in Oman. But so many places here are quite green. Why?

The Omanis invented a water distribution system hundreds of years ago called the aflaj-system. Water coming from the mountains or rising from lower levels of the soil is directed to open canals to agricultural areas. In former times the appointed wali of the local community determined different time slots for each family or community to receive access to the canal. Today the five main aflaj-systems in Oman are on UNESCO’s World Heritage List and therefore are highly protected.