This only works for the first dollar after the you stop taking the standard deduction.
For most people, the standard deduction is freaking huge now due to the changes under Trump - for married couples in 2024 it will be $29,200.
So you have to have deductions that equal almost $30k before they start to "matter". If your itemized deductions would be about $10k (mortgage interest, perhaps, SALT, etc) you would have to donate $20k before you would start to see some effect from the donations.
There are still some ways to do pre-tax donations even without that, but you may have to involve estate-planning trickery.
"When you donate stock to charity, you’ll generally take a tax deduction for the full fair market value" [1].
[1] https://www.fidelitycharitable.org/giving-account/what-you-c...