As stated, it is because they don't eat little crustaceans and krill in the Salmon farms. These critters have Astaxanthin in them (same stuff that makes flamingoes pink).
Astaxanthin is just the pigment that is naturally produced by these animals. It can be synthetically produced using yeast or algae - the synthetic stuff is chemically identical to the naturally-occurring stuff.
I feel like the implication when you see "farmed salmon is grey" is typically "and therefore it is bad/toxic/unhealthy/unnatural, etc". Really, the color just means they just have less naturally occurring astaxanthin in their diet. Astaxanthin is an antioxidant and is good for you - and plays a role in the growth and development of the salmon. However, when it is produced synthetically and added into the fishes' feed to give them color & aid their development, it has the same effect as if it were from krill.
There are problems with salmon farming (environmental and animal welfare issues, though there can also be disease and contaminant issues dependent on farm location/conditions), but the actual meat is not nutritionally very different from wild salmon. It can actually have similar or even higher omega-3 content because farmed salmon are fatter (though their fat is higher in omega-6 and lower in omega-3 than wild-caught salmon).