Contact Mechanics Modeling Of Homogeneous And Layered Elastic-Plastic Media: Surface Roughness And Adhesion Effects