Template not working for the custom Post type

You registered the post type with the name ‘theme’?

Also when changing templates and anything that has any correlation to url-s always reload or load the page admin->settings->permalinks. Sometimes without this, the changes won’t take effect.