You are asking the question based on the modern metaphors and using scientific terminology. This does not apply to the metaphors that the Torah uses. The Torah uses the heart as the seat of the will and desires of a person (יצר טוב and יצר הרע) As a result, it expresses matters in that way.
This is not a matter of modern science. This is what the Torah metaphors are used for. The brain would be pure logic, the heart the will and desires, the liver and kidneys the emotions. All of these are nowadays referred to the brain, but in tanach and the talmud that is what the metaphors are used for.
The heart is not the seat of the emotions, that is the modern English usage. In the Tanach, it is the seat of the will and personality not the emotions.
This is explained in Some Body Part Metaphors and Euphemisms in Biblical Hebrew
- The total personality of a person. Most particularly for the inner self - what it means to be human – personality/inclination
- intellect, rational thought (metaphorically “the brain” in English)
- desire, will, determination,
The emotions are basically used to refer to the liver or the kidneys.
Rav Hirsch on VaEschanan says
על לבבך - Accordingly the demand here is, that the words spoken here
as being our duty are to be kept present in our minds and exert a
permanent influence on our hearts, accordingly on our feelings and
Additionally a number of meforshim point out that the literal translation is your (singular hearts (plural). This mean both the yetzer tov and the yetzer harah in a person must be influenced and controlled by the command of Hashem. Thus, the לב is the seat of the yetzer of a person, the will and desires.
Similarly, the Torah commands
This shall be fringes for you, and when you see it, you will remember
all the commandments of the Lord to perform them, and you shall not
wander after your hearts and after your eyes after which you are going
and you shall not wander after your hearts: Heb. וְלֹא תָתוּרוּ, like “from scouting (מִּתּוּר) the Land” (13:25). The heart and eyes
are the spies for the body. They are its agents for sinning: the eye
sees, the heart covets and the body commits the transgression. - [Mid.