Phoenix is one of the best places to build a city in the entire southwest. It's at the confluence of two major rivers (the Gila and Salt), near a lot of decent agricultural land, and connected by canal to an extremely large river (the Colorado). It's geologically stable and land is cheap. The population is relatively high, relatively educated, and the state government is willing to give companies huge concessions to be there.
People have been building along the Sonoran rivers for thousands of years and they'll probably continue for thousands more.