Starter sometimes doesn’t start

Hello together, I would need your help. I changed a starter with an Omega X20XEV because the old one somehow slipped through with some start attempts and therefore did not start the moter. At the exchange starter the problem occurred again. At some point, after about 1/2 hours without start attempts it works again. Can there be an ignition lock problem here evl.? Greeting Uwe