Being interested in something is a skill that can be cultivated in itself. Of course, you probably won't be able to convince yourself that something you find unbearably dull is interesting, but you can deepen a vague interest into curiosity towards and appreciation of the details and nuances.

It's not about joyless grinding or forcing yourself, more like putting yourself in a space where you engage with the thing and deciding to go just one step further than the point where your attention initially starts to drift. Or just putting yourself back in the space of thinking about it when you have a free moment, like waiting in a queue. You can use that time to, for example, make up a few sentences in the language that you're learning (perhaps about how annoying the queue is), or playing music in your head.

It is slightly more difficult in the moment, but in the long term it makes your life experience richer and more fulfilling than if you pulled out your phone and started scrolling (which you can still do afterward). You don't have to be mercilessly beating yourself about productivity, but if you develop these kinds of habits you tend to naturally start doing it more often.