Topological construction of phosphorus and carbon composite and its application in energy storage