Another thing is that - as usual with Apple - there’s no way to adjust or reset such suggestions. Even without the „all mail“ folder, it was hit & miss. And why would a folder that has been added later override all previously learned suggestions? It’s just stupid.
(BTW, the same goes for login/password suggestions in Safari, even when using Bitwarden - for my Cloudron site, Safari suggests 30 login / password combinations that are out of date. No way to reset that).
I hear you. Apple always does everything the apple way. In this case I think its not really related to "learning". I think its more of a scan and match system. You receive a mail and the mail app is looking up for the folder containing the most mails with the given sender. So in case of Amazon apps there are like two options: The Amazon folder and the all mail folder. As I may have missed a few mails in the past and probably just moved them into the archive, there may be a slightly higher amount of mails in the all mail folder. Also I tend to use folders like "cancellations" or "payments" which may also contain Amazon mails.
The same goes for office mails. The same sender (f.g. boss@work) may end up in folder "Project A" and Project "B", according to its content and topic. But both mails will be found in "all mail". So no matter what, the all mail folder will - due to its nature - always have the biggest and max. possible amount of mails from every given sender and therefor get the highest "rank" from Apple Mail.
At least thats what I assume.