Privacy-preserving Consensus-based Energy Management in Smart Grid