P-persistent homology of finite topological spaces