Computers use binary because digital circuits have two states: on or off, high voltage or low voltage, current or no current. Representing more states reliably is harder.
A transistor (the building block of all computer chips) acts like a switch. It is either conducting (1) or not conducting (0). Trying to distinguish between 10 voltage levels would require precise measurements and would fail under noise or manufacturing variations.
Binary is simple, reliable, and fast. Every bit of data in memory, every CPU operation, every network packet uses binary. When you write code, the compiler translates it to binary instructions.