bloss, your ds sounds like he has an advanced grasp of cause and effect. I think it's good that you are still considering this is attention-seeking behaviour. You've said you've given him loads of attention already but he still might want more. He might not see things as reasonably as you do Even if he wants his sister along on your days out, he might still expect your attention to be focussed on him while his sister comes second.
School rules and expectations, like not fidgiting or interacting with children in class while the teacher is speaking, should reinforce the fact that this winding up behaviour is 'naughty' even at its early stages. So keep hoping!
Do you think your son will be keen to get good behaviour marks at school? He strikes me as possibly being a competitive and/or a perfectionist sort of person, as you say he is highly focussed and not prone to peer pressure, so won't be easily lead. I could be wrong, but if he is keen to do his best, he might take very well to the school rules and want to be the child who gets the most bonus points of the week etc.
I think you all you can do for now is keep talking to him, make it clear you will not tolerate winding up behaviour even in its early stages, and give him lots of positive reinforcement...and cross your fingers this is a phase and school will change his approach.
PH hope my brains have proved worth picking - I am off work with a temperature at the moment, so I am not at my best