Added pagination to the list of documents