best way to preserve ricotta?
Seasoning does not preserve food. Some foodstuffs normally used for seasoning, like salt and vinegar, can help to preserve food, but the concentration you need will make your ricotta unpalatable. 

Salting can preserve food, when combined with dehydration. Bacteria need a humid environment to live in. Salt is hygroscopic, it both helps dry out the food you are preserving (usually meat) and directly dehydrates any bacteria which come in contact with it, killing them. Even then, you want to use charcuterie salt (a mix of NaCl and NaNO2) to prevent botulism, as pure table salt (NaCl) doesn't kill Clostridum Botulinum. 

Trying to get ricotta preserved that way is counterproductive. Not only will it be way too salty to taste well. You will also have to dry it out to the point where neither mould nor bacteria can grow on it. Hard cheeses are durable exactly for these reasons, but dried-out ricotta is not tasty. In fact, I am not sure that "the yellow stuff" you see is "toxic", it could just be dried-out. Still, I wouldn't be willing to risk eating it, even if the taste was acceptable. 

You could try preserving your ricotta by adding acid. To have it hold a long time in the fridge, it has to be as acidic as a typical pickle recipe. I only mention this because you say that you spice it heavily. But frankly, I can't imagine anybody wanting to eat ricotta that sour. 

The option I would choose is freezing. You already mention "the freezer", but if you are really freezing it, then it sounds like you are thawing and refreezing the whole container. Alternatively, maybe it was a slip of the keyboard and you meant to say that you are holding it in the back of the fridge. Whatever you meant, I would suggest freezing it in portions, for example using silicone muffin moulds. Once you have frozen your ricotta (you can add spices it first, if you prefer), remove it from the moulds and place it in a freezing bag. Only thaw the amount you will need for a single meal. This should work well enough, in the worst case you'll have a layer of freezer burn to remove.