In the Add Loan page under Advance Settings section, there is a field called Override Maturity Date. There you can put the maturity date. In Number of Repayments, select a high number for example 200 so that the system stops at the maturity date.

For more details, please visit the Add Loan Help page.