What manoja2k said holds true, let me elaborate a bit. You have to buy an iPhone (lets say 3G, for 99 USD) but you have to purchase a data service which costs 30 USD per month, and you are tied to a 2 year contract.Thats how AT&T absorbs the price of the iPhone.
You *can* break contract, but that requires you to pay a cancellation fee (175 USD IIRC) and a month of usage charges on top of the 99 USD for the Phone. TE peeps who are more knowledgeable about the iPhone/AT&T contract please correct me here.
Anyways, you can check the Terms from AT&T yourself here:
link