G1 (or Gap 1) occurs after cytokinesis - the
last cell division - but before the start of DNA synthesis. This
is where the cell spends most of its time doing whatever the cell
is meant to do.
S phase (or Synthesis phase) is the time when
DNA is synthesized. This ensures that the mother cell will pass on
identical copies of "her" genetic materials to both
of her daughter cells later on.
G2 (or Gap 2) occurs after S phase but before
the next M phase. At this point the cell is getting ready for
M phase by providing the necessary materials for mitosis or meiosis.