A few weeks ago we saw that the Hebrew term for Thanksgiving is חג ההודיה
הודיה is derived from the verb להודות
I (a male) thank you (a female) for the kind (pretty) words.
But להודות also means to acknowledge or to admit, for example:
She admits her (the) guilt.
Note that the preposition …ב
What is the connection between thanking and admitting? Both involve acknowledging a fact, though in different ways.