Does anyone here know on how to block search engine from indexing the products within this url http://www.domain.com/ ? Because I want search engine to index http://www.domain.com/folder but both url has the same content. I don't want search engine consider them as duplicate so I need to block all the products within http://www.domain.com/ and every page within this folder http://www.domain.com/folder should be index by search engine.
The only way to do what you describe is to exclude each page in the root folder, page by page. A folder and all below it is either allowed, or not. You can't disallow a folder and then allow one of its sub-folders. Better yet, remove the duplicate content. If you have moved it from the root to a subfolder, use a 301 redirect on each page to the new page in the subfolder.