I verified the tips on the page below. The only mistake I’ve noticed is that the date format is wrongly indicated, i.e. instead of in MM/DD/YYYY format, the dates have to be specified in DD/MM/YYYY format.
So, the 1) command should be:
$ zmmailbox -z -m alice@example.com gru "//?fmt=tgz&query=after:"20/07/2022"&before:"26/07/2022"" >> /tmp/alice.tgz
https://wiki.zimbra.com/wiki/How_to_export_import_emails_for_a_specific_date