public Document withId(String id) {
        setId(id);
        return this;
    }
<p>
A identifier of the document in the index.
</p>
<p>
Note, each document ID must be unique per index. You cannot create a data source to index your documents with
their unique IDs and then use the <code>BatchPutDocument</code> API to index the same documents, or vice versa.
You can delete a data source and then use the <code>BatchPutDocument</code> API to index the same documents, or
vice versa.
</p>

@param id
       A identifier of the document in the index.</p>
       <p>
       Note, each document ID must be unique per index. You cannot create a data source to index your documents
       with their unique IDs and then use the <code>BatchPutDocument</code> API to index the same documents, or
       vice versa. You can delete a data source and then use the <code>BatchPutDocument</code> API to index the
       same documents, or vice versa.
@return Returns a reference to this object so that method calls can be chained together.
aws-java-sdk-kendra/src/main/java/com/amazonaws/services/kendra/model/Document.java