Generally, it's unsafe to refreeze food that has been thawed, as it increases the risk of bacterial growth. However, if the frozen food was thawed in the refrigerator and remains cold, it *may* be safe to refreeze after cooking.
When frozen food thaws, bacteria that may have been present before freezing can start to multiply. Refreezing doesn't kill these bacteria; it only slows down their activity again. If food has been thawed at room temperature, it's best to discard it if you're not going to cook it immediately. Thawing in the refrigerator is the safest method because it keeps the food at a consistently cold temperature, minimizing bacterial growth. If you thaw food in the refrigerator and decide not to use it, you *can* refreeze it, but there may be a loss of quality due to moisture loss and changes in texture. The best practice is to only refreeze food that has been thoroughly cooked after thawing. Cooking to a safe internal temperature will kill most harmful bacteria.
To avoid having to refreeze thawed food, portion your food into smaller, manageable sizes before freezing. This way, you only thaw what you need, minimizing waste and the risk of bacterial contamination.