Nix shell basically just downloads the software (if it's not already downloaded) and then modifies your PATH to include the new software.
Persistent data stay persistent.
Nix shell has one use case common with docker (local development), but other than that the solutions are not similar at all.