Rigidity and flexibility phenomena in general relativity