The phone must be Java-enabled, i.e. it must say something like "MIDP compatible" or "supports Java", etc. You then follow the manufacturer's directions for getting
Java apps on the phone. Most of the time that means using a data cable connected to your PC. The newer phones can download stuff wirelessly as well, although that's pretty slow and for development purposes you'll want to use the cable.
For a list of Java-enabled phones, see
http://www.javamobiles.com.