How do I specify UID?

UIDs are generated by Zero. If you want to set your own UIDs, you could try the method provided here.

/assign?what=uids&num=100 This would allocate num uids and return a JSON map containing startId and endId , both inclusive. This id range can be safely assigned externally to new nodes during data ingestion.