There are several different reasons the IRS may choose to freeze the funds in your bank account. If you have significant tax debt that you have not made payment arrangements for, they do have the legal right to seize the money you have, and that process starts by telling your bank to freeze the funds in your bank account.
They may also freeze your account if you are non-compliant with other demands, if you ignore IRS communications, or if the account is used to engage in fraudulent activity.