If you are trying to increase or decrease an email account's quota an error that can occur is the Invalid maildirsize error:
This can happens when the maildirsize file has become corrupted. Fortunately, resolving this issue is a fairly easy process.
By using the cPanel File Manager you can delete the maildirsize file that is causing the error.
If you are not already logged into your cPanel, log into your cPanel account.
If you are already logged into cPanel and you are in the Email Accounts area of cPanel, return to the cPanel Home Screen.
Click on the File Manager icon, choose "Home Directory" and click the "Go" button.
Double click to open the "mail" folder and then the domain name of the email account (after the @ symbol in the email address).
Inside the domain name folder, navigate into the email user name (the part of the email address before the @ symbol).
Inside of this folder you will see a file named maildirsize. This is the file you will want to delete. Yes, it is safe to delete this file and will resolve the error you received when trying to change your email account quota.
Once you have deleted the maildirsize file, return to the Email Accounts area in cPanel and continue with changing the quota.