a shear thickening fluid (approximately) may serve your purpose. Its viscosity increases considerably when stressed. Best example is a wheat flour dough. Initially it has low viscosity but as you start applying force to make is uniform it becomes more viscous.
Density wise I can't think of an example (density increasing considerably with applied stress) in semi solid and solid materials.