hello! first of all you need to be on the right baseband to unlock the 3gs...
Before you can follow these instructions you must have a jailbroken iPhone and you must be on the 04.26.08, 05.11.07, 05.12.01, 05.13.04, 06.15.00, or 01.59 baseband(modem firmware).