how to implement a document management system