Without leaving the main App ID, with changing to a SandBox account in TestFlight and managing subscriptions
create a test SandBox account in AppStore Connect
under the main App ID install the application from TestFlight (close your application if you have opened it)
go to iOS settings -> App ID -> Content & Purchases -> Exit (if it does not exit after tapping, go back to the screen).
tap again Content & Purchases -> login as a test account
test
if you want to manage subscriptions -> iOS settings -> AppStore -> sandbox account -> login under test account