Denmark is buying 27 F-35. That not nearly enough to do anything meaningful against an enemy like Russia. Buying a plane, like the SAAB JAS 39 Gripen, would have allowed the Danish Airforce to do basically the same operations, for much much less money. The Danish airforce isn't going to intercept Russian fighters. The missions are patrol and bombings for NATO.
For a country like the US, sure, maybe the F-35 is something they need for the type of missions they fly. I just can see any country do anything with 27 planes. 27 is less planes than an aircraft carrier has.