Cheese is an artisan good made from processing milk in a Cheese Press, taking approximately 3.3 in-game hours. Once crafted, it can be consumed for energy and health, gifted to villagers for friendship points, or sold for profit. Its quality and value increase if made from large milk or aged in a cask, potentially becoming iridium quality for a higher selling price. It's also an ingredient in several cooking recipes and a bundle in the Community Center.
The item ID for Cheese is 424
This ID will work on PC/Mac (Steam), PS4, PS5, XBOX One, and Nintendo Switch.
Spawning items in Stardew Valley is a little unsual and is not done with commands. You will need to utilize what is called a cheat to set your character's or animal name to the item id. To do this you cannot use just the item id, you will need to surround the item id with brackets. Ex. [424]
Spawning Using the Animal MethodTo spawn Cheese while using an animal, you will need to head over to Marine's Ranch and purchase an animal. Once you have have an animal chosen, name the animal with the item id with brackets like this [424] and you will receive the Cheese item. This method can be done using an existing character and is convenient but will cost some gold every time you want an item.
Spawning Using the Character MethodTo spawn Cheese while using a character, you will need to create a new character and name it with the item id with brackets like this [424]. You will then receive the Cheese item when you speak to a villager. This method is easy and free but cannot be performed on an existing character and you will be stuck with that name unless its edited.