William Penn was a Quaker in England. This religious denomination was generally unpopular in England and suffered persecution. Penn had been an important individual in English society at the time of his conversion, and he used his position and his wealth to protect as many Quakers as he could.
Ultimately, he used his position to obtain a royal charter for the land between the Maryland and New York colonies. This new colony became Pennsylvania. The purpose of Pennsylvania was to provide land and protection to Quakers in England. By establishing the colony himself, Penn had the authority to establish protections for Quakers and other religious groups in the founding documents of the colony. This allowed Penn to protect his fellow Quakers from persecution, the original purpose behind the colony.