Specifically, if an iPhone can no longer run the latest version of Apple's iOS operating system, it will miss out on many critical security updates. Vulnerabilities that aren't fixed can put you at risk. Apple is discontinuing hardware service for some technologically outdated products. Your product is backed by continuous operating system updates and is backed by a network of more than 5000 Apple-certified repair centers that you can trust in case something unexpected happens.
You can continue to use the device if your iPhone is no longer receiving software updates. You're only using an older version of iOS and can't use the latest features. You'll continue to receive security updates, but not as often. That way, you can keep using your iPhone safely.
While it's just an estimate, Apple currently offers iPhone models for about seven years, so this should give you an idea of how long the replacement will last (assuming the hardware holds up). This suggests that while the iPhone 6s may receive software support for a while, it may not be possible to repair it if it breaks. The only real option that allows you to use the latest version of iOS is to buy a new or used iPhone that's still getting support. Statista (a provider of market and consumer data) publishes a graph showing how long Apple is compatible with older iPhones.
Apple will offer support for iPhones (and all the devices it makes) for seven years starting from the last time it sold that particular model.