We present an RGB-D based SLAM system capable of building consistent 3D maps of large indoor environments. The system performs motion estimation by using keypoint correspondences between frames. A novel data association approach is developed for accurate mapping with robust loop closure detection. To achieve this, the proposed method uses a Keyframe Autocorrelogram Database and an adaptive thresholding technique. Keyframe Autocorrelogram Database indexes and clusters past frames based on their spatial color correlations and returns short and long loop closure candidates as k-sized clusters by using a data structure that can effectively handle high dimensional data. The adaptive thresholding technique, which was introduced in our previous work, filters out more outliers in the clusters and selects better loop closure candidates. The proposed approach incrementally produces environment maps without needing any training step. The system is tested on widely used public datasets with a large group of sequences. The experimental results show the robustness and efficiency of our system in challenging conditions, in comparison to other state-of-the-art systems. The system produces accurate maps for medium and large-scale environments with stable and fast processing times on CPU. Thus, the proposed approach makes possible real-time operation with efficient implementations.