Your passport is an important, official document issued to you by your country for the purposes of travel and identification. We recommend that you make photocopies of your passport; carry your passport only when you will need it for travel, and leave it at home in a safe spot the rest of the time.
You are responsible for knowing when your passport will expire. No Canadian immigration documents will be issued to you beyond the date of the expiration on your passport. If your passport will expire before you would normally complete your studies, your study permit validity will not extend beyond your passport expiry date.
You can renew your passport inside Canada at your consulate or embassy. You will also need to apply separately to extend your study permit, after your passport renewal has been approved. Make sure to keep track of both expiration dates as well as estimated processing times. Do not let your study permit or passport expire. You should begin the passport renewal processes well in advance (at least six months).