According to the Code of Canon Law 332 §2, "If it happens that the Roman Pontiff resigns his office, it is required for validity that the resignation is made freely and properly manifested but not that it is accepted by anyone."
There are three things worth noting.
1) First, the Pope may resign from his office as Pope.
2) Second, this resignation cannot be coerced by external agents.
3) Third, the Pope does not tenure his resignation to anyone one or to any corporate body.
Pope Celestine V resigned from the papacy in 1294. Pope Gregory XII resigned from the papacy in 1409.