I know NavyLCDR is right on the purchase. In all states you must be 21 to purchase a handgun from a Federally Licensed Dealer (FFL) but private sales are regulated by state law.
It also appears he is right about being 18, now that I have looked at actual AZ law. I think two statutes most on point are ARS Link Removed and Link Removed, both of which deal with minors, or those under 18.
My apologies for the previous incorrect information.