I guess now I understood what your question was. Indeed there are a lot of software that can do what you want but I guess your premise is wrong since this is not related to create a table of content for the document but to index the document content allowing -- at least from what I understood - complexes searches.
Normally this is done trough software not to index, by to manage content. For example a CMS. (https://en.wikipedia.org/wiki/Content_management_system)
In that way, the search and the indexing procedures are not performed by MS Word but for some other system. Please note that the search service from windows and linux commands will allow to do the same kind of searches but they will work locally only.
Just as an example, I work with eZ Publish (http://ez.no/Products/eZ-Publish-CMS). It uses Solr (http://lucene.apache.org/solr/) to index the contents and the very CMS performs the searches. Of course I'm talking about Client/Server software, quite complex but, since you want people to search, I think you will have any kind of server to share content.
I guess wordpress (http://wordpress.org/) can do it using plugins, but I'm not sure.
In any case, if you want to share searches and information, I think your premise is wrong since it will not be on word document level but one step higher, in the software that will share and manage the content. Maybe you should talk to your editor about that or the webadmin or the developer that will share/sell/distribute your book
I really hope I wasn’t too technical. This is quite hard to explain. Anyway, if this answer goes towards your question and you have any more doubts, comment here and I'll try to explain in a clearer way.
I just reminded something. Google can index PDF files and allow searches. You can add a custom search box for your site, for example, assuming that's the way you want to share content. Please check http://www.seoconsult.com/seoblog/seo-techniques/can-google-fully-index-pdf-files.html