When you start, just try to find a build that is balanced. In most cases, a balanced build is better than an pure offensive or a pure defensive one. Most new players build way too offensive or way too defensive.
After you get some experience with balanced builds, start counter building. If the enemy compose mostly of AD, build more armor. If the enemy compose of mostly AP, build more resist. If the enemy compose mostly of armor, build armor pen or magic damage. If the enemy compose mostly of magic resist, build magic pen or more physical damage.
But for starters, just focused on building a balanced champion.