ReSo: A Reward-driven Self-organizing LLM-based Multi-Agent System for Reasoning Tasks