On regularity and rigidity of degenerate Sobolev deformations of n-dimensional domains