Pilots are taught to work with the fact that Earth is a sphere. It is part of the education to become a pilot. Their job depends on the knowledge that Earth is a sphere.
Flat-Earthers wrongly claim that pilots are taught to fly based on a flat Earth. We can easily disprove these claims by reading some of the books these pilots use in their education.
Flat-Earthers based their claim on various factors. There are some social media accounts, like Pilot LX, that present themselves as pilots who believe Earth is flat, but probably nothing more than troll accounts. While they repeatedly claim that they are pilots, and they believe Earth is flat, many of their photos show Earth’s curvature. Adding a caption telling that “Earth is flat” does not diminish the fact that the curvature is there. We can almost hear them laughing after seeing flat-Earths applauding them in the comment section of their video that clearly shows Earth’s curvature.
Some flat-Earthers encountered real pilots who told them “Earth is flat,” but they appear merely trying to free themselves from the annoying flat-Earther as soon as possible, and as politely as possible.
Some pilots might even be actual flat-Earthers. Pilots are human beings, and they are not immune to psychological problems, just like people of another profession. Quite obviously, these people are a clear minority. Just because a few pilots have this particular psychological problem, it does not mean all pilots are like that.
In the end, the fact remains, pilots were clearly taught to work with the fact that Earth is a sphere. And it is easy to verify that from their educational materials themselves.