Hi, XXXXXXXX
Most hardware stores will have non skid sticky backed material that you can purchase.
If you want to do it cheaply you can cut up some old bicycle tubes (ask at the bike shop or a local tire store) and then glue them to the metal tubes of your futon with some 3M weather strip adheasive. (ask at the auto parts store for a tube if gorilla snot they'll know what it is)
If this does not work then the only other option would be to sew on some type of lacing so that you can tie the matress to the top rail of the futon.
I hope this has answered your question. If it has then please be sure to click the accept button.
Best regards; The Home Smithy
Jack of all trades Master of a few.
#1 Home Improvement Expert. Over 30 years experience in construction, and home repairs