That depends on at what point in the call you need to enter the account code.
If you dial the number, hear a tone, then enter the account code, that means the carrier is handling it. You won't see that in the Mitel records. That isn't something you can change.
If you dial the account code first, then the number, that means the Mitel is handling the account codes. In that case, check your SMDR options to be sure it's enabled.
Ralph