Rhymes (especially rhymes at the ends of lines) are a trademark of traditional English poetry. When two consecutive lines in a poem rhyme, that’s a couplet. The heroic couplet adds a steady beat. Take for example this line from “Couplets on Wit” by a master of the form, Alexander Pope:
Now wits gain praise by copying other wits As one Hog lives on what another shits.
Heroic couplets use the “iambic pentameter” rhythm, meaning each line has five measures (called feet), with two beats (syllables) per measure. The beats are in iambic order, which is generally considered to be a normal speaking cadence. The second syllable is always stressed, while the first hangs on lightly before (now WITS gain PRAISE by COPYing OTHer WITS).
Figuring out the rhythm for a poem is more difficult than seeing the rhyme. Generally I’ll write whatever comes in my head naturally and then revise it. I read back over and change words to make them more precise and metered. This process is a little like molding clay. To really understand meter and rhythm, find a better explanation at the Poetry Foundation (or wherever) and read poetry.
In print, Chaucer pioneered the heroic couplet with his epic Canterbury Tales, but it probably existed before him. The couplet appears in other poetic forms, like the sonnet, and it is one of the oldest poetic devices to appear in printed Romantic languages.
If you want to better understand the form, here are a couple of good places to start:
Dryden established the Heroic Couplet in the late 17th century: http://www.bartleby.com/218/0912.html
Alexander Pope perfected the form in the early 18th century, and it’s never gotten better than this: https://www.poetryfoundation.org/poems/44899/an-essay-on-man-epistle-i
Pope's poetry can get difficult, but he often wrote to destroy Enlightenment era elitism: http://poetry.eserver.org/rape-of-the-lock.html