First Hack after lot of Googling
I have screwed up with my iCloud account by changing its password and Apple ID.
At last I got stuck into situation where my iCloud Account on my mac uses older Apple ID. I could not sign out from my iCloud Account in Mac Preferences.
After lot of struggle I got to know that preference files are stored under ~/Library/Preferences/. And then I tried a hack as last resort of trial. I have searched for files which has string "iCloud" under my ~/Library/Preferences/ in Terminal app with the help of below command
grep -r "icloud" ~/Library/Preferences/
I got many results. Among them one result is below.
Binary file /Users/MyUserName/Library/Preferences//MobileMeAccounts.plist matches
I opened that file. I see "Accounts". When Expand that I see below details about my old iCloud details with Account ID and etc. And I confirmed myself that account ID is my older iCloud account and from AccountDescription's value is iCloud.
I deleted the blue coloured selected Item 0.
Later I opened iCloud Preferences. Now it asked me to login to new iCloud account.
Yahooo..... My problem solved. Hope this help you. Be careful while deleting iCloud details. Confirm yourself that you are deleting your unwanted old iCloud account.