What are the functions performed by kidneys?

Kidneys perform following functions :
(1) It removes metabolic waste products.
(2) It regulates the water content of body fluids.
(3) It regulates pH of body fluids.
(4) It regulates the chemical composition of body fluids
by removal of substances which are in excess of immediate requirements.