Visit to US before F1 using the Visa Waiver Program

I am going to start a phd at the US with an F1 visa. University told me that I could enter the US only 30 days before the date on I-20. Since English is not my first language (and this would be a big change in my life) I would like to go there by June.
The thing is that I have an European passport with a valid ESTA. My plan would be to arrive with this passport, stay 4-6 weeks , go to Canada for a short vacation (maybe flight maybe by land) and come back to the USA with F1 visa.
I have two questions about this:
1) is this possible?
2) If yes, how could I justify knowing I will lose my come-back flight during my first entry? (I would purchase round trip because one-way are too expensive, probably with less than 90 days difference)
Pictures about "Visit to US before F1 using the Visa Waiver Program"



About Visa Waiver Program | How to travel in US without a visa | Visa Waiver Program USA 2021 | DHS
Sources: Stack Exchange - This article follows the attribution requirements of Stack Exchange and is licensed under CC BY-SA 3.0.
Images: RF._.studio, Vlada Karpovich, Sora Shimazaki, Ketut Subiyanto