The electric motor just turns into a generator and charges the battery. Engine breaking with an EV is literally refilling your tank, so to speak. The modern EVs are pretty smart about it and will also apply the breaks sneakily if the engine can't bring up enough resistance (due to battery being charged, too much change in a short time, etc.)
I will also add that the break pads in EVs are criminally underused to the point that they reach their maximum service life with barely any usage on them.
If you want a comparison, it's basically like flicking on the little dynamo engines on a bicycle and then turning on the light. It'll slow you down a lot quicker than without the light on. Same principle here and works just as well.
Regenerative braking is not Engine braking, which itself is not at all like using brakes other than it slows the vehicle down. Though it is probably most commonly used to spare brake wear, the importance of it is to help the driver maintain control of the vehicle. Active use of engine braking by shifting into a lower gear helps control speed while driving down very steep and long slopes, and to maintain better control in serpentine curves while at high speed.
The simple fact of the matter is it is not possible to engine brake in an EV, because it is not possible to reduce to a lower gear. EV is better than ICE in nearly if not every other way, but let's not take it too far. The driver of an manual ICE vehicle will be able to have better control at faster speeds than an EV on curvy, non-flat roads solely due to the ability to engine brake, but this probably isn't legal driving.
How is regenerative breaking not the same as engine breaking? Other than the lack of ICE in the EV, the engine is being used to slow down the vehicle, it has the exact same effect.
Well it’s not the same in a similar fashion of “1 + 1 = 2” is not literally the same as “3 - 1 = 2”. Maybe they accomplish similar goals but downshifting to brake can be done for as many gears as the transmission contains in a stepwise fashion. But without a transmission in a single speed vehicle with regenerative braking it’s more of a “spectrum” of braking and not directly controllable by the driver.
And for the record I believe “engine braking” is a slightly different mechanism than “downshift braking” but could be wrong here - my manual passenger vehicles don’t have explicit “engine brake” controls but a semi truck might.
Downshift Braking is Engine Braking, it's the same thing. And there is absolutely no reason an EV motor could not emulate the exact same behaviour as a stick shift. It's all electronic, you could just emulate the behaviour of a stick shift vehicle there and give the user a joystick with stick shift labels on top. All the motor has to do is to either apply regenerative breaking at a certain efficiency value. The electronics can ramp regenerative breaking from 0% to 100% in any amount of steps you like.