The reason that one of the three values: mass, diameter, density is always locked is because one of the values (the locked value) is always dependent on the values of the other two:
From the diameter you can compute the volume so the functions are these:
mass = volume * density
or
density = mass / volume
or
volume = mass / density
Does that help?