The standard passenger constant-flow mask primarily has the bag so that the FAA requirement of flow indication can be satisfied. Additionally, the standard aviators oxygen mask that we know of today has evolved from a medical mask where knowing if a person is breathing and getting the prescribed amount of oxygen is indeed happening. The accumulator (sometimes mistaken as a re-breather) bag does all this. The accumulator bag also helps to keep oxygen contained and ready for each inhalation phase.
An aviator’s full face oxygen mask may contains up to three valves to control the dilution of the breathing phases. The first valve opens to allow the oxygen to be inhaled from the accumulator bag; the second valve allows the discharge (exhaust) of exhaled air to the out side of the mask and not back into the bag.
If the check valves are not operating properly, you may re-breath too much of you own CO2 or not get the prescribed amount of oxygen for the altitude you are exposed to. Also if the bag has cracks or holes, you will not get the prescribed amount of oxygen.