Did you want to apply for international protection (asylum) when you tried to cross the border?
In other words, have you tried to tell the Border Guard, during border controls, that you are fleeing persecution in your country and therefore should be allowed into Poland even though you do not have valid documents such as a visa or residence card?