The iconic yellow jersey, as seen in the Tour de France, is worn by the cyclist with the best cumulative time. It first goes to the Stage 1 winner and is then passed on to the rider with the best overall time each day. One can still retain the yellow jersey even if the cyclist does not win the stage that day. In the Giro d'Italia, the leader's jersey is pink. In the Tour of Spain, red.
In the Tour of Alberta, the red jersey is worn by the Canadian rider with the best cumulative time.
Think of cycling as having multiple competitions within one race. There's General Classification (GC), which tracks the best overall time, with the yellow jersey being awarded. Then there's points classification, which is secondary. One of the competitions under points classification is sprinting. Riders earn points and the day's best sprinter wears the green jersey.
Another secondary competition is King of the Mountain or Queen of the Mountain in women's cycling. Riders earn points when they crest hills. Whoever has the most points wears the polka dot jersey.
In the Tour of Alberta, the rider who's under the age of 24 with the best overall time wears the white jersey, representing the best young rider.