Get some microphones. Condenser microphones record instruments and vocals well. This type of mic needs to run through a pre-amplifier that supplies phantom power. Dynamic mics work, too, but are limited to picking up loud instruments such as electric guitars or drums. Two inexpensive and excellent microphones are Audio Technica's AT-2020 and Shure's SM-57. You will need XLR cables to hook these microphones to your audio interface.
Obtain an audio interface for your computer. Interfaces connect either through firewire or USB ports. M-Audio produces a variety of interfaces that are high in quality and low in cost. You will need to decide what works best for your intentions. If you are recording multiple musicians, you will need to find an interface that has many inputs on it. The size matters, as well; if you will be working mostly in a studio, you can get a very large complicated interface, but if you're a traveling producer with a laptop, you'll need something smaller.
Buy some recording software. There are free open source programs available such as Audacity. You can purchase programs such as Acid Pro or Cake Walk. Apple's OSX comes with an excellent program called Garageband.
Look at the instructions for your interface and hook up your microphone(s) accordingly. The interface should then be connected to your computer. You may need to purchase a firewire or USB cable if the interface did not come with one. Then, click "Record" on your audio software and let your music flow.
Use a good set of headphones or speaker monitors to listen to the playback of your recording and make sure the recording is to your liking. When you are done recording, you can mix down what you have done and export your file to a digital media player such as iTunes or Windows Media Player.
Burn the music from the digital media player onto a CD. Media players work in different ways, but generally you'll need to select songs, insert a blank CD, and click "Burn." To use iTunes as an example, after you have exported your files to iTunes they will show up in your library. Make a new playlist by clicking the "Plus" button in the lower left corner of the iTunes window. Click and drag your songs from your library to the new playlist. Click on the "Burn a disc" button in the lower right corner of the iTunes window. You will then be prompted to insert a blank CD-R. Do this, then the computer will write the CD for you. Check the CD on the computer to see if it works. You can then play the CD from iTunes, where it will appear in the left pane under "Devices."