Use the No Contact node to define boundaries with not contact contribution. Excluding boundaries can be useful to reduce the computational cost if it can be determined before solving the model that some parts are unlikely to take part in contact problem.
Physics tab with General Contact selected in the Model Builder tree: