Gmail does delete inactive accounts. According to Google's policy, if an account is inactive for a certain period of time, it will be considered as abandoned, and it will be deleted by Gmail. However, the specific time frame for when an account is considered inactive is not publicly stated.
Google does not delete inactive Google Workspace accounts (that includes Gmail) so long as you keep paying the bill.
More info: https://support.google.com/accounts/answer/3036546?hl=en