Corrosion is the spontaneous disintegration of metals due to chemical or electrochemical reactions with the environment, causing the formation of compounds like oxides. It occurs as metals strive to return to stable states from higher energy levels, forming oxide films that can be protective or porous. Various methods exist to control corrosion, including proper design, material selection, environmental modifications, and the use of inhibitors.