My previous laptop was a MacBook Pro 13, which I kept for five years due to waiting out the the butterfly switch fiasco.
I opened a support request yesterday, during which the rep acknowledged Apple recognizes this problem, and was offered service. The good news is that this is a known issue at Apple. I have a (Bellroy) sleeve to protect the laptop, and transport it in a dedicated bag that is very lightly loaded just an A5 notepad, water bottle, and small zip case for cables. I bought screen cleaner and a microfibre wipe, and with prompt cleaning can see marks appearing regularly. My current laptop is a MacBook Pro 16 I bought in May, about four months ago, and noticed key marks on the screen straight away. The screen doesn't have enough clearance, is in contact with the keyboard when closed, and gets marked.
The short answer is you can't prevent these marks.