I've noticed that the Rust standard library distinguishes concepts of Unix file descriptor and Windows file handle. However, as far as I understand, both can serve either as a reference to the open file that can be used for I/O or other manipulation, or a reference to some other object for some other tasks, and Rust standard library interface to them look similar. I wonder, what is the reason for such distinction?
Only conceptually. Implementation-wise: most of the OS-specific details are going to be completely different. In the world of Unix, "everything a file". In Win32, every "handle" may require to be "handled" according to its own set of rules and protocols. Mixing them up for the sake of convenience and/or uniformity, although somewhat more practical on a surface level, would be a recipe for disaster.