This setting in the web.config applies only to the Web Forms version of EpiServer, if you are using the MVC version this setting will not function. Instead you will need to use the built in ASP.Net MVC ContentOutputCache attribute at the action level in your controllers. To vary the cache by ID you would add:
[ContentOutputCache(VaryByParam="id")]
public ActionResult Index(StartPage currentPage)