Double-click the "GarageBand" icon to open the application. When the program launches, go to the "File" menu, and click the "New" option.
Click the "New Project" option on the next screen. You are presented with a choice of project templates. Click the "Keyboard Collection" icon, then click the "Choose" button near the bottom right corner of the window.
Connect the synthesizer keyboard via the computer's MIDI interface. The MIDI port is located on the sound card or near the audio in and audio out slots.
Click the "Add Track" button in the GarageBand application, then go to "Track," and click the "New Track" option. On the next screen, click the "Software Instrument" icon, and click the "Create" button.
Double-click on the instrument from the keyboard collection that you wish to use to record a MIDI track.
Get ready to play on the keyboard. When you are ready, click the "Record" icon near the top of the application window. The instrument records as you play on a track in the timeline view. When you have finished playing, click the "Stop" icon. You have recorded a MIDI track with a real synthesizer keyboard.