How to position mattress in storage room?

i know it’s a weird question and I tried finding something online about this but no luck. We have queen mattress that we need to put in a storage room for about 2 years. It’s a nice mattress, so we want to keep it. It will most likely have to be placed standing up and my worry is that it may lose it’s shape? Does anyone know if it will ? Should we have boxes pushed against it, to prevent the shape deformation? thanks.