add doc returns doc key, add remove doc by id method, and test cases for both