ENH: Move IndexingError to error/__init__.py per GH27656
- [x] xref #27656. this GitHub issue is being done in multiple parts
- [x] [Tests added and passed](https://pandas.pydata.org/pandas-docs/dev/development/contributing_codebase.html#writing-tests) if fixing a bug or adding a new feature
- [x] All [code checks passed](https://pandas.pydata.org/pandas-docs/dev/development/contributing_codebase.html#pre-commit).
- [x] Added [type annotations](https://pandas.pydata.org/pandas-docs/dev/development/contributing_codebase.html#type-hints) to new arguments/methods/functions.
- [x] Added an entry in the latest `doc/source/whatsnew/v1.5.0.rst` file if fixing a bug or adding a new feature.

I moved the `from pandas.errors import UndefinedVariableError` statement to the top for `pandas/tests/frame/test_query_eval.py` as a follow up from a comment on https://github.com/pandas-dev/pandas/pull/47338.

Thanks again @dataxerik (failures were unrelated)