Values in table not changing after being told to

So I recently coded a neural network and one of the key components of a neural network is mutations. However, for some reason when I tell the weights of the network to change is just doesn’t.

rng = math.random(1, 3)

if rng == 1 then
	WeightL2[9] += math.random(-1000, 1000) / 5000
end

That is the code for a weight to change and this is what prints.

                    [2] = -0.623,
                    [3] = 0.708,
                    [4] = -0.6060000000000001,
                    [5] = -1.0142,
                    [6] = -0.916,
                    [7] = -0.487,
                    [8] = -0.451,
                    [9] = 0.95

                    [1] = -0.076,
                    [2] = -0.623,
                    [3] = 0.708,
                    [4] = -0.6060000000000001,
                    [5] = -1.0142,
                    [6] = -0.916,
                    [7] = -0.487,
                    [8] = -0.451,
                    [9] = 0.95

It’s the exact same thing even though it was told to change. I have no idea why this is happening any help would be appreciated.