1 It is responsible for the production of bile which is stored in the gallbladder and released when required for the digestion of fats. 2  The liver stores glucose in the form of glycogen which is converted back to glucose again when needed for energy. 3  It also plays an important role in the metabolism of protein and fats.