Subtract the empty container
Weigh a dry, empty measuring cylinder. Add the liquid, read its volume and weigh again. Liquid mass = filled mass − empty mass. You can also tare the empty cylinder before adding liquid.
Example: 90 g − 40 g = 50 g of liquid.