As others have already said, for your own story, there's nothing stopping a warlock from becoming a lich.
Personally, I don't like it, for a number of reasons:
1. Classically, in order to become a lich, you had to be a wizard or cleric who undertook very specific rituals to achieve lichdom. Admittedly, there was no warlock class in those days, but IIRC the other high level casters (such as druids and illusionists) couldn't do it either.
2. Flavor-wise, the characters able to become liches were essentially the 'learned' ones, the ones who invested time and study into magic to learn how to command it. That strikes me as being exactly the *opposite* of what the warlock embodies -- warlocks are these Faustian creatures who make a deal with the devil (often literally) for short-term gain at the expense of their long-term welfare.
3. Also flavor-wise, it seems like the patron wouldn't be very happy about the warlock becoming a lich. I'm giving you power in exchange for your soul, and then you change up the deal so I'll never be able to get your soul? It just feels like these powerful beings who are granting these powers would have the metaphysical equivalent of a contractual clause in the pact that stops a loophole like lichdom from taking effect. I mean, unless the warlock is the first mortal to ever try this, it just seems like common sense, and beings powerful enough to be warlock patrons are generally pretty savvy.
4. Related to #1, but a lich is a fairly specific entity. It feels like there are lots of other story mechanisms available to warlocks to become immortal that make a lot more sense -- becoming a fiend/extraplanar being/member of the Fae courts, for example.
So, YMMV, but I personally would be disinclined to let a warlock become a lich.