The primary role of ventricles is the forcible pumping of blood around the cardiovascular system, to provide the necessary resources to the tissues of the body.
There are two ventricles which form the lower chambers of the left and right hand sides of the Heart. They are larger than the upper chambers, called the atria. The ventricles provide the high blood pressure needed to circulate blood around the entire cardiovascular system due to their high muscle density, with the left ventricle having larger walls and thus more muscle. This is necessary due to the fact that it pumps blood around the body, as opposed to the right ventricle which only pumps to the lungs.
When in systole, the muscles of the ventricles contract, increasing the internal pressure of the ventricle and thus forcing blood out through the aorta and the aortic valve (in the case of the left hand ventricle), and into circulation. The right hand ventricle works identically, however instead of supplying systemic circulation with blood, it instead supplies the pulmonary artery (and then lungs) through the pulmonary valve.
In diastole the ventricles relax, so the pressure within the ventricles is lower than that of the atria, thus allowing the blood in the atria to flow through into the ventricles through the tricuspid (right ventricle) and mitral (left ventricle) valves.