Paul never claimed to have written Hebrews although the book is consistent with his theology and knowledge of Jewish religious traditions. It is likely it was written by his close companion Barnabus, an educated Greek Jew.
I believe I read something years ago that made a pretty convincing argument that Barnabas could not have written Hebrews, but I don’t remember what the argument was. Martin Luther suggested that it was written by Apollos and made some good points, some have also made good arguments that it was written by Clement of Rome. I don’t think any scholars actually believe it was written by Paul, though many Christian leaders adhere to Pauline authorship based on tradition.
We're not sure about 1 Peter, but 2 Peter was written 50-100 years after Peter was martyred. The Gospel authors were not identified when written (a sign of arrogance and hubris). The Church put the names on them ca. 225 AD or so, IIRC.