title: Why does db.insert(dict) add _id key to the dict object while using pymongo
body: <p>I am using pymongo in the following way:</p>
  
  <pre><code>from pymongo import *
  a = {'key1':'value1'}
  db1.collection1.insert(a)
  print a
  </code></pre>
  
  <p>This prints</p>
  
  <pre><code>{'_id': ObjectId('53ad61aa06998f07cee687c3'), 'key1': 'value1'}
  </code></pre>
  
  <p>on the console.
  I understand that _id is added to the mongo document. But why is this added to my python dictionary too? I did not intend to do this. I am wondering what is the purpose of this? I could be using this dictionary for other purposes to and the dictionary gets updated as a side effect of inserting it into the document? If I have to, say, serialise this dictionary into a json object, I will get a</p>
  
  <pre><code>ObjectId('53ad610106998f0772adc6cb') is not JSON serializable
  </code></pre>
  
  <p>error. Should not the insert function keep the value of the dictionary same while inserting the document in the db.</p>