Hello,
These black dots can be due to seborrheic keratosis, viral warts or some benign skin growths. Seborrheic keratosis is a benign skin growth and the cause is exactly not known but sunlight and hereditary predisposition have been proposed. To confirm the diagnosis, you need to get a biopsy skin done.
It is very difficult to precisely confirm a diagnosis without examination and investigations and the answer is based on the medical information provided. For exact diagnosis, you are requested to consult your doctor. I sincerely hope that helps. Take care and please do keep me posted on how you are doing.