In the past, people have squeezed Prosody onto their routers with 32MB RAM and the like. Today you might struggle fitting the Modern XMPP experience into that, but 512M or 1GB should be plenty.
As for storage, it really depends on how many and how big pictures or other files are shared. Clients like Conversations will compress images into a few hundred KB by default, so you can imagine how many will fit into even 1GB. Text messages take even less space.