With your main job, everything is indeed straightforward - the employer will calculate and transfer everything themselves. But with freelancing, you need to figure it out, because how you formalize it affects your taxes.
The most popular option right now is registering as self-employed through the FTS app. It's minimal bureaucracy: you don't need to open an LLC, no complex reports needed. You pay 4% tax on income if your clients are individuals, or 6% if they're legal entities. You submit the registration application online in five minutes. You're not required by law to notify your main employer, but check your contract - some companies have a clause prohibiting side work. If there's nothing like that, then you can work on the side without worry.
The second option is to open an LLC, but that only makes sense if your income is large. The taxes are higher there, you need to file reports, make pension fund contributions. If freelancing is just a side gig, self-employed status is way more convenient. With self-employment, also keep in mind that your annual income shouldn't exceed 2.4 million rubles, otherwise you'll have to switch to a different tax system.