Added 'keys' method, modified 'upsert' function, and started docstring
testing and documentation.