DriveItemUploadableProperties upProps = new DriveItemUploadableProperties();
upProps.name = "vacation.gif";
upProps.additionalDataManager().put("@microsoft.graph.conflictBehavior", new JsonPrimitive("rename"));
// Create an upload session
UploadSession uploadSession = graphClient
.me()
.drive()
.root()
// itemPath like "/Folder/file.txt"
// does not need to be a path to an existing item
.itemWithPath(itemPath)
.createUploadSession(upProps)
.buildRequest()
.post();