Problem with f-stop on Nikon D90?

I just bought a NIkon D90 and a 50mm lens that I got specifically for its small aperture, which is 1.8.
It will only let me shoot if I move the aperture ring to 22. I don't understand. Can I not shoot with a 1.8 aperture then?

You have misunderstood the reason for locking the lens at f/22. This is to tell the camera what the smallest aperture is so it can meter correctly. Look at the bottom of page 26 in your user manual.
Had you done that and tried using your camera, you would have seen that you have complete access to all the apertures your lens has.

Need to use the front command dial on the camera to change aperture for Auto Focus lens.