Exactly the problem. XP does not contain the drivers you need for AHCI mode, Vista does. If you need to install XP first because you have an upgrade version of Vista, just the set the controller to IDE mode. Install XP, then just before you insert the Vista install disk, go back into the BIOS and change to AHCI mode.
If you just want to install XP only, and you want to run in AHCI mode, you have to supply the drivers to the XP install via the "F6" key when prompted.