There is no formality required in writing a rental agreement. Just write on a piece of paper the names of the landlord and tenant, the address of the place to be rented, the monthly rent and when it is due, and whether the term is month-to-month or some set period (like six months) - and then have both parties sign it and keep copies. Those are the basics, but you should also write down anything else that is important to you, such as the amount of any security deposit and how clean you must leave the place to get the deposit back, any repairs the landlord promised to do, and whether you may keep a pet.
You may obtain a form agreement from a book store or stationary store, but watch out. Those forms are often packed with language that favors the landlord and contain little that favors the tenant. If you can't find a form that is more balanced, it might be better just to write it out the basics yourself.


