There are many circuits for current limiters.
Have a look here for some of them:
https://www.google.com.au/search?q=...po6IB7rmgJgE&ved=0CAoQ_AUoAQ&biw=1024&bih=566
Here is one circuit that works
You have to calculate a value for the sense resistor that will make it drop 0.6 volts at the required current.
In this case, it will be about 30 ohms.
Using Ohm's Law,
Resistance = Voltage / current = 0.6 volts / 0.02 amps = 30 ohms.
But, as Physguy mentioned, you can't have it both ways. If you supply 12 volts to a 100 ohm resistive load, it will draw 120 mA.
Using Ohm's Law,
current = voltage / resistance
current =12 volts / 100 ohms = 0.12 amps = 120 mA
To make it draw only 20 mA you must reduce the voltage to 2 volts.
Using Ohm's Law,
current = voltage / resistance
current = 2 volts / 100 ohms = 0.02 amps = 20 mA
Ideally, what you need is a circuit that will give you a steady 12 volts out except if the load resistance is low enough that it will draw more than 20 mA. In this case, the output voltage must reduce enough that the load cannot draw more than 20 mA