[SPARK-40578][PS] Fix `IndexesTest.test_to_frame` when pandas 1.5.0
[SPARK-40578][PS] Fix `IndexesTest.test_to_frame` when pandas 1.5.0

### What changes were proposed in this pull request?

This PR proposes to fix the test `IndexesTest.test_to_frame` to support pandas 1.5.0

### Why are the changes needed?

The behavior of `Index.to_frame` is changed from pandas 1.5.0, but we cannot follow the behavior since we have a limitation for mixed type.

So we should create expected DataFrame manually to make the test pass.

### Does this PR introduce _any_ user-facing change?

No.

### How was this patch tested?

UT fixed, and manually tested with pandas 1.5.0.

Closes #38016 from itholic/SPARK-40578.

Authored-by: itholic <ed4f4f56e5cf0fd9096ce83e1cd0aa9ad7c7a706@databricks.com>
Signed-off-by: Hyukjin Kwon <2680965ad5aae29275c8fb10150cb10f5554e78b@apache.org>

srowen/spark,HyukjinKwon/spark,vinodkc/spark,ueshin/apache-spark,holdenk/spark,wangyum/spark,zzcclp/spark,holdenk/spark,vinodkc/spark,witgo/spark,vinodkc/spark,mahak/spark,wangyum/spark,shaneknapp/spark,zzcclp/spark,holdenk/spark,apache/spark,wangyum/spark,zzcclp/spark,dongjoon-hyun/spark,zzcclp/spark,dongjoon-hyun/spark,srowen/spark,hvanhovell/spark,shaneknapp/spark,holdenk/spark,apache/spark,HyukjinKwon/spark,apache/spark,mahak/spark,HyukjinKwon/spark,mahak/spark,dongjoon-hyun/spark,witgo/spark,witgo/spark,hvanhovell/spark,shaneknapp/spark,shaneknapp/spark,wangyum/spark,hvanhovell/spark,ueshin/apache-spark,HyukjinKwon/spark,wangyum/spark,HyukjinKwon/spark,zzcclp/spark,vinodkc/spark,zzcclp/spark,srowen/spark,vinodkc/spark,hvanhovell/spark,holdenk/spark,dongjoon-hyun/spark,shaneknapp/spark,hvanhovell/spark,dongjoon-hyun/spark,ueshin/apache-spark,ueshin/apache-spark,srowen/spark,wangyum/spark,srowen/spark,ueshin/apache-spark,shaneknapp/spark,vinodkc/spark,apache/spark,dongjoon-hyun/spark,apache/spark,mahak/spark,ueshin/apache-spark,hvanhovell/spark,holdenk/spark,apache/spark,holdenk/spark,HyukjinKwon/spark,srowen/spark,vinodkc/spark,shaneknapp/spark,hvanhovell/spark,witgo/spark,witgo/spark,apache/spark,mahak/spark,mahak/spark,witgo/spark,HyukjinKwon/spark,mahak/spark,ueshin/apache-spark,wangyum/spark,witgo/spark,dongjoon-hyun/spark,srowen/spark,zzcclp/spark