The way it works is this:
When TurboTax detects that you have excess HSA contributions, if they were made through your employer (code W in box 12 on your W-2), then it is immediately added back to your federal income as Other Income on line 8 of Schedule 1 (1040).
That is because the HSA contributions in box 12 were removed from Wages in boxes 1, 3, and 5 before your W-2 was printed, so any disallowed contributions (the excess) needs to be added back so that you pay tax on it.
Then TurboTax asks you if you will withdraw the entire excess before the due date of the return (July 15th this year but usually April 15th). Any excess that is not withdrawn will be carried over to next year and penalized at a 6% rate.
Then, next year, your HSA contribution limit is reduced by this carryover amount, so if you are smart, you will reduce your HSA contributions - or else you will just generate another excess and be penalized again.
Note that this reduced HSA contribution limit won't be shown on your return or in TurboTax (although TurboTax will know it if you did your return with TurboTax last year) - you just have to remember this yourself.
If you did not use TurboTax in the previous year, when TurboTax asks in the HSA interview "Did you overfund your HSA last year?", answer "yes" and enter the amount that was carried over - not the whole amount of the excess but only what was carried over.
If you withdraw the entire before the due date of the return, then the matter if over and done with - TurboTax has added it to Other Income, and that's all that needs to happen (except for you contacting your HSA custodian and actually requesting a "withdrawal of excess contributions").
Oh, in the year after you request the withdrawal of the excess, you will receive a 1099-SA with the earnings that your excess made while in the HSA in box 2 of the 1099-SA - enter this into your return.
Does this answer your questions?