REF: `axis in [..]` with `_get_axis_number()` 
- [x] xref #43048 
- [x] Refactored test_frame_apply.py 
- [x] Created if-else constructs by replacing `if axis in [...]` by `_get_axis_number`
Done. Please check.
Thank you. lgtm pending green