You can install them as excellent, just select individual directories. I have Xcode 3 installed in its vanilla location (/ Developer), while Xcode 4 is in '/ Developer / XCode4'.
To change the installation location: on the "Installation Type" screen in the installation program, you will notice that the "Developer" folder, indicated next to the top installation item, is actually a drop-down list - click on this icon, then select "Other". to select a custom location.
source share