Add option for primary key function

Procrastinating on moving pkey logic into the storage class.

https://github.com/maxogden/dat/issues/51