Say in the heart
Here’s what it means
A person thought, reasoned, resolved, or said something inwardly.
Why the Bible says it this way
An idiom is a familiar phrase whose meaning comes from the whole expression, not from reading each word by itself.
A helpful detail: The phrase reports inner thought, whether or not the words were spoken aloud.