You can’t record over a portion of a track. What you do is:
Select the bit that you want to overwrite, and silence it. You can silence it with “Edit > Remove Special > Silence Audio” (Ctrl+L), which is a “destructive” edit, or using the envelope tool, which is a bit fiddly, but is a “non-destructive” edit.
Extend the selection a bit so that you have a lead in / out (pre-roll / post-roll).
Press Record (shortcut “R”). The new take goes onto a new track. You can then trim / adjust / crossfade as necessary.