The short answer to your question: in the body.
Mahabharatha, Aswamedha parva (40.11)
“Tamas is found in great measure in the sudra, rajas in the
Kshatriya, sattva in Brahmin”
Ramanuja’s commentary on Bhagavad Gita, Chapter 18.41.-47 states
The deeds of the past determine the present dispositions of men. These
dispositions bring about the relative potencies of the Guṇas in each
case. The Brāhmaṇa has Sattva dominating over Rajas and Tamas. The
Kṣatriya has Rajas in predominance and the other two stand suppressed.
In the Vaiśya Rajas and Sattva are subdued and Tamas is slightly
dominant. In the Śūdras Tamas is very dominant and the other two are
overpowered. The Śāstras properly lay down these qualitative
demarcations and formulate the corresponding obligations and
occupations of the four groups of men.
According to Vedanta Desika (Srimad-Rahasyatrayasara, Chapter 25)
https://archive.org/details/in.ernet.dli.2015.92385/page/n362/mode/1up
The qualities of caste pertaining to the body are due to the special qualities of the body, arise at birth and remains until death.
However, a person can have the predominance of Tamas in the
composition of his body but can very well obtain the quality of sattva
in his mind.
The above chapter exclusively talks about the sattvam of the body and the sattvam of the mind and how they are different. The body in the above verse refers only to the body and not to the body-mind complex (or that body includes the mind). Accordingly, the guna of the body can not be changed till death but the guna can be changed in the mind.
Vishnu Purana (6.2.6) extols a person though have a body of Sudra becomes accomplished due to Jnana.