An RGB LED is actually three LEDs (red, green, and blue) in one package. When you run them at different brightnesses, the red, green and blue mix to form new colors.
Starting at the flattened edge of the flange on the LED, the pins are ordered RED, COMMON, GREEN, BLUE.
Connect RED to a 330 Ohm resistor. Connect the other end of the resistor to digital pin 9.
Connect COMMON pin to GND.
Connect GREEN to a 330 Ohm resistor. Connect the other end of the resistor to digital pin 10.
Connect BLUE to a 330 Ohm resistor. Connect the other end of the resistor to digital pin 11.