Is it legal for a bank to charge a $10k "Maturity" fee at the end (maturity date) of a loan if the balance is not paid in full.

We have a loan with a major bank of 37,400, they have set payments of principle and interest at $1000.00 per month. If we pay as agreed and at the end of the loan period there is still a balance, can they charge this fee?