There is a twist in Canadian law regarding mortgages.
Quoting from the page linked below.
---
Canada’s Interest Act states the following about amortizing mortgages: “... the principal money and the rate of interest chargeable on that money, calculated yearly or half-yearly, not in advance.”
---
This page does go into the detail a little more.
https://wowa.ca/how-is-mortgage-interest-calculated
It may not be authoritative but you can start with https://laws-lois.justice.gc.ca/eng/acts/i-15/page-1.html which should be.