Added MongoDB support.

I've opened issue #81 related to this PR
I thought that it's better to set index field explicitly instead of guessing it.