The issue is the same/similar to
JENKINS-44860 with masking "App ID" (which treats as username) of "GitHub App" type credentials. The issue was solved for "Username Password" credentials by adding "Treat username as secret" which is absent for "GitHub App" credentials type.
The following doc was used to get App ID and token: [https://www.jenkins.io/blog/2020/04/16/github-app-authentication/#how-do-i-get-an-api-token-in-my-pipeline.
As "App ID" is a number, it masks all such numbers in the console output: