What country are you in? Apple Retail and Apple online (Apple Care) have different rules and policies. Not drastically, just different out of necessity because of the personal interaction you have in a store. Apple can see a lot about a device with just the serial number.
I’m a former Apple Store manager and never had to request a receipt for a device for a warranty repair. But we would definitely need a legible and unaltered serial number on the device. Generally the serial number appears in several places, not just the exterior of the device. I’ve seen devices with one serial number on the outside and different one on the inside. Apple methods of detecting potential fraud are pretty extensive. But if the serial number shows good, you should be good on your warranty. However, remember there are still terms and conditions of the warranty itself that must be followed too.
Congratulations on your new Apple iPhone and enjoy the experience. 😀