Confocal microscope is an observation microscope with high resolution comparing to average optical microscopes. It detects an object by dots and makes 2D picture by connecting the dots.
Because it is possible to construct 3D data, including objects with rough surfaces, it can take an image of surface layer with cross section. And also, it is possible to observe cross-sectional imaging because it has resolution to Z direction.