A coroutine can be thought of as an instance of suspendable computation, i.e. the one that can suspend at some points and later resume execution possibly on another thread. Coroutines calling each other (and passing data back and forth) can form the machinery for cooperative multitasking.
Coroutine vs Thread
Coroutines are similar to threads, but they are not the same thing. Threads are managed by the operating system and can run in parallel on multiple processors, while coroutines are managed by the program and run on a single thread