Go to DIRECT mode, type MML, and press the question mark button on the top-right corner of the lower screen. Read through that; it will explain all of the MML commands. After that, you can directly play MML with BGMPLAY "MML string" or use BGMSET to save a song to play later.
Usually I would use MML stored in DATA commands myself. To do that, write a label where the song will be, and write as many DATA commands as needed to create your song. (You can write as much MML with one DATA command as you want, but adding more makes the code more readable.) Where you want the song saved, write:
BGMSETD song number,label
In BGMSETD the song number is where you want to save the song - you must specify this same number to play your saved track with BGMPLAY. The label must be the same label your song data is written in.