Why the lights?
It's like the "third degree" in old cop movies. In those, often someone was forced to sit in a dark room and made to stare at a bright light. That would blind them so they couldn't see faces, only silhouettes of people. It depersonalizes everyone else and makes it harder for the victim to identify with anyone and it makes them even more alienated from everyone else.
While Madred wasn't using the lights in the same way, the likelihood is that they were hot and bright, both of which would be hard on Picard. Every time Madred made him look at the lights, he would be temporarily blinded and would feel pain from looking into the lights. While that's not a major source of pain, it carries the message that Madred is in control and that even on the small things, he intends to not give Picard a break.
While he could have used anything, like the color of a wall or the shape of his desk, by using lights, he was able to create more confusion by blinding Picard (at least temporarily) and causing him discomfort every time he made Picard look at the lights. It was just another way to get under Picard's skin, and it was more effective than using the color of something or the shape of his desk.
As to the number, he was likely just working with the lights that he had in the room. Likely any number of lights from two to four would work. It's tough for someone to see one light and say it's two, and once you start with five lights, it's harder to count them and easier to confuse five with six. But with two, three, or four lights, even when Picard was drained from torture, he could still count four and know there were four, even if he gave in.