Does density of a substance change when the volume of the substance change?

For example, if I had 10 mL of water and it has the density of 1g/mL will the density change if I had 20 mL of water instead?

No, density is density.

density = mass/volume. So the mass can change and the volume can change but the mass of a substance over the volume of that substance does not change.