I’m also fairly new to NixOS and also nix flakes, but there isn’t much to be daunted by. A nix flakes config and a normal nixos config are identical except for the inclusion of a flake.nix file which declares what inputs (sources) you’re using, otherwise it’s identical. I’d recommend taking a look at this video which covers NixOS configuration as well as switching to nix flakes. The timestamp I included drops you off at the nix flake section of the video.
Once you’ve got that understood you can either find or write a nix flake for the program you want and include it in your config and use the modules from it. If you write it you’ll need to make a derivation as verstra has said in another comment, which just says how to get the source files, what dependencies are needed for building, what dependencies are needed for installing and how to build and install it. This video goes into some details about derivations which may help.
It’s a lot more involved than other distros but it gives you more control. I’m not fully switched over yet but i do want to switch over as soon as i can.
Glad I could help a bit