Yes, it can. It is best to stick to constant volume products, if possible, for best accuracy and repeatability. It is possible to measure density and bring an input to the sensor for compensation.