In 3-dimensiaonal contact, the cylinder as well as piston bodies can be a flexible body.
Figure 1 2-dimensional contact
More:
Modeling Options
Properties