pandas.PeriodIndex and pandas.DateTimeIndex docstring quotes fix
- [x] closes #27713
- [ ] tests added / passed
- [ ] passes `black pandas`
- [ ] passes `git diff upstream/master -u -- "*.py" | flake8 --diff`
- [ ] whatsnew entry

I think if you run black against the files modified should fix CI Thanks!