Alexander's conquest of Egypt was part of his broader campaign to conquer the Persian Empire. Egypt had been under Persian rule for over a century, and the Egyptians resented their foreign overlords. Alexander's arrival in Egypt was therefore initially welcomed by the Egyptians.
However, Alexander quickly came to be viewed as a foreign conqueror himself. He imposed heavy taxes on the Egyptians and forced them to provide soldiers and supplies for his army. He also replaced many of the Egyptian administrators with Macedonians and Greeks.
As a result, there was growing discontent among the Egyptians, which eventually led to a series of revolts. However, Alexander was able to suppress these revolts and maintain his control over Egypt.
So while it is true that Alexander conquered Egypt, it is not accurate to say that he liberated it.