Refresh_token is not returning

Hello,

I created an App in developer console to integrate my test app via OAuth 2.0.
I configured permissions on ‘Jira platform REST API’ and set Refresh token behaviour as ‘Use rotating refresh tokens’.

Getting authorization code and Exchanging authorization code for access token were successful.
However, when I tried to get refresh token by adding ‘offline_access’ to the scope parameter of the authorization URL, it does not return refresh token, it returns (authorization) code and status. Same response with or without ‘offline_access’. If I test the code with https://auth.atlassian.com/oauth/token, then it says ‘{“error”:“invalid_grant”,“error_description”:“Unknown or invalid refresh token.”}’

authorization URL:
https://auth.atlassian.com/authorize?audience=api.atlassian.com&client_id=CLIENT_ID&scope=offline_access%20read%3Ajira-work%20manage%3Ajira-project%20manage%3Ajira-configuration%20read%3Ajira-user%20write%3Ajira-work%20manage%3Ajira-webhook%20manage%3Ajira-data-provider&redirect_uri=https%3A%2F%2Flocalhost%2Ftest.html&state=${YOUR_USER_BOUND_VALUE}&response_type=code&prompt=consent

I searched several postings on this community but could not find resolution.

Are there any missing steps in App configurations?
Or are there any pre-requisites on the web page of callback URL to get refresh token?

How can I get the refresh token?
Can you please provide detail steps and samples on how to get refresh token?

Thanks in advance.
Regards.