The vapor trails left by airplanes are commonly called contrails. They form when the hot, humid air from jet exhaust mixes with the environmental air. The mixing is a result of the turbulence generated by the engine exhaust. This is similar to the cloud you see when you exhale and "see your breath" in the winter.
How long a contrail remains intact depends on the humidity structure and the winds up where the contrail formed. If the air is real humid, the contrail may exist for a long time. If the atmosphere is dry, the contrail will mix and dissipate. The winds also effect whether the contrail remains a narrow band, or becomes a puffy cloud or a thin layer.