The OS (like Windows or Unix) accomplish running multiple threads on a single CPU by means of
context-switching. Each thread (and any other program running simultaneously) gets to do its think for a very short period of time, after which the OS does a context switch to give another thread a short period of time to do operations. See
Context switch on Wikipedia. Only on a multi-core or multi-processor computer to threads can run truly simultaneously.