@Ravi Khambhati The default health probes merely ensure your application is up (startup), running (readiness), and accepting requests (liveness).
While this may be sufficient for most applications, you may want to have a custom endpoint based on your scenario like when you need to ensure certain background services are fully initialized before accepting requests.
For example, your custom health endpoint could perform multiple checks like database connection validation, upstream/downstream service health checks, setup ephemeral database entries or files, acquire distributed locks, etc.
Depending on the language your application is built with, you might have a framework provided approach to creating these custom endpoints as well. In C#, ASP.NET Core provides a neat way to define many health checks and adds the health check endpoint directly without having to code it yourself.
As for why your container's health check is failing, it would be best to start checking its logs to see why the TCP probe fails. The check itself is simply making a connection to your app on the TCP port. So, it could be that your application is not listening at times or if you are using a process manager that is restarting your service within the container.