In principle, you're looking for a "document-oriented database": https://en.wikipedia.org/wiki/Document-oriented_database
CouchDB is what I usually see recommended as an alternative to MongoDB and might fit your bill (although I haven't worked with it yet): https://couchdb.apache.org/