For those, like me, trying to and unable to sign onto iCloud with Apple TV 2nd/3rd generation TAKE NOTE THAT THIS IS NOT FIXABLE. Error message indicating that the "account is not set up" is incorrect. Apple Support just told me that this function (ICloud to Apple TV) is not longer available. See below for older posting- NOTE THIS POSTED SOLUTION DOES NOT WORK.
Past posting from others:
"If you have an Apple TV (2nd or 3rd generation) and two-factor authentication for your Apple ID, then you may be asked to type your password followed by the six-digit verification code directly into the password field. Additionally, there is a time limit, after which the code becomes invalid.
Try this: First enter the characters of your password (do not submit yet), then manually request a new verification code, then append that code to the password (no spaces or other separating characters), and then submit. That should help you get passed the time limit."