A politician has accused a prison of helping foreign criminals obtain British citizenship by providing study materials for inmates.