I found that a good fraction of unwanted emails have the header "Return-Path" equal to "<>", so I thought that I could have an email rule to test for this and then move the email to a junk folder. However, this rule does not work.
As a test--for one such email--I looked for another header that had a short value. In that case email header "X-Originatororg" had the value "norcalasa.org", so I added a test for that value, which moved the email to junk. That test worked.
What am I not understanding?
I am using a MacBook Air 2017 running MacOS Big Sur 11.6, with Mail version 14.