Open a new document on your computer, or write by hand in a notebook. The tools you use depend on where you are when you become inspired and what feels more comfortable. Make it a habit to keep a notebook and pencil near your bed so that when you wake up you can jot down a few notes.
Decide on the rhyming sequence you'd like to use for your poem. Sometimes a single line will come to you, and you can work from that. However, when planning a poem from scratch, it's best to know in advance what kind of rhythm or beat you'd like to have.
Start out by using end rhymes, or rhyming at the end of each line in an ABAB format. Write your poem like the one written below:
A) Roses are red,
B) Violets are blue,
A) Sugar is sweet,
B) And so are you.
Notice how the "B" lines rhyme but the "A" lines do not. You can also write it so that the "A" lines rhyme with one another, or you can write couplets where lines "A" and "B" work together. Start out with a couplet so that your line "A" rhymes with line "B." Move onto longer, more complex stanzas when you're comfortable.
Build up your poem by adding stanzas or collections of lines within the poem. Think of each stanza as its own paragraph. Each stanza ties in with the poem's overall theme but may look at the subject from a different angle or be a continued thought from the last stanza.
Note that a big part of writing poetry is knowing how and when to stylize it. Finish off lines with commas, periods, semi-colons, exclamation points or even em dashes. Keep in mind that each form of punctuation will cause your reader to pause or rest for a specific amount of time. Use periods when you want a long pause, or use a comma for brief pauses.
Try writing a rhyming poem where the rhyming takes place within the same line. Take the following line for example:
There were grapes on the floor of the grocery store.
The words "floor" and "store" rhyme. You can use any rhyming technique you like and even mix them together. Remember that the content of your poem comes down to its subject and how you perceive it.