Friction in unconforming grain contacts as a mechanism for tensorial stress–strain hysteresis