Khalwat appears to be a Muslim Arabic term based on my reading in Understanding Islam by Thomas W. Lippman. Khalwat literally means sex between unmarried men and women which is rampant in most of the world, but was/is prohibited in Malaysia.
The working meaning of Khalwat is close proximity between the sexes. One can certainly understand the jurisprudence or philosophy associated with this being outlawed. The sexual impulse is strong and one way to avoid unwanted pregnancies is to not allow for the precondition of proximity which certainly avoids copulation.
Many Western Christian families practice this not as a tenet of Christianity, but as a pragmatic decision avoiding a costly and family wrecking pregnancy. We know Church of Christ families that chaperone their daughters on their high school prom dates which indicates they believe in Khalwat even though they certainly not acknowledge it given the tension between the two religions these days.