import bpy

lista = []
import random, math
for _ in range(1000):
    alpha = random.random()*2*3.14
    r = random.random()*5 + 5
    angle_i = (random.random()-0.5)*0.05
    x = r * math.sin(alpha)
    y = r * math.cos(alpha)
    z = r * math.sin(angle_i)
    lista.append((x, y, z))


bpy.ops.object.select_all(action='DESELECT')
bpy.ops.mesh.primitive_ico_sphere_add(subdivisions=1, radius=0.05)
sphere = bpy.context.object

for loc in lista:
    ob = sphere.copy()
    ob.location = loc
    #ob.data = sphere.data.copy() # uncomment this, if you want full copies and no linked duplicates
    bpy.context.collection.objects.link(ob)
