BUG: Fixes dataFrame to_string(header=False)
- [x] closes #49230 
- [x] [Tests added and passed] if fixing a bug or adding a new feature

- [x] All [code checks passed].
- [x] Added an entry in the latest `doc/source/whatsnew/v2.0.0.rst` file if fixing a bug or adding a new feature.

Nice fix @andrewchen1216! 