The pleurae are vital to the integrity of the lungs because -
They produce a lubricating serous secretion, allowing the lungs to glide over the thorax wall during breathing.
The pleura secrete a serous fluid called pleural fluid. The pleural fluid fills the space in between both the pleura, called the pleural cavity. This fluid ensures that the pleura is well lubricated and reduces friction when they slide against each other, and the rib cage, during breathing.
The contraction of the diaphragm creates a negative pressure within the pleural cavity, which forces the lungs to expand, resulting in active inhalation and passive exhalation. This breathing process can be made forceful through the contraction of the external intercostal muscles which forces the rib cage to expand and add to the negative pressure in the pleural cavity causing the lungs to fill with air.