rss feed code help

Not entirely sure. This is template tag and should be used in Loop, but for single post page it works fine most of the time even outside of Loop. Seems to from quick test.

Disregard that. The issue is you were forgetting to echo it. 🙂

Also there is specialized template tag for comment feeds: get_post_comments_feed_link().

and is there any plugin where as soon as i publish a new post, automatically the rss feed is also created of it???

Not sure what you mean here. When post is published it automatically appears in main site’s feed.