Locked codes are for players looking to claim free Yen (in-game currency), the most important in-game resource used to unlock new characters, traits, and every other item inside the in-game shop.
V-Bucks in Fortnite act as the in-game currency that can be acquired through real-world money or be earned via Battle Pass.