How you get an invite varies from developer to developer. There is no set method. Some advertise the opportunity on Twitter or other social media. Some do so on their own web sites. Some only invite known and/or trusted associates to test their app. Very few developers offer open test flight invites. They want people who will test their app and report on it, who can be expected to give detailed and reliable feedback. It's not something that they just throw open to the general public. Though I'm sure there are exceptions.
In general, access to apps in test flight is not available to the general public. Especially those who just want to use the app early. That's not the point of test flight.
For your second question, when an app becomes incompatible with a version of iOS, or the developer removes it from the App Store, you will no longer be able to view it on your device. Sometimes the developer removes an app for sale, but leaves it on the App Store. In that case, if you've purchased it before, you can see and re-download it under purchased apps in your App Store account. Tap on your account icon in the top right of the store to access your account options.