#include <bits/stdc++.h>
using namespace std;
const int N = 1e5 + 7;
const int M = 1e3 + 1;
const int base = 1e9 + 7;
const long long mod = 1e9 + 7;
int n, m = 20;
vector<int> ke[N];
int f[N][25], pa[N], h[N];
void khoitao() {
  for (int i = 1; i <= n; i++)
    for (int j = 0; j <= m; j++) f[i][j] = -1;
  for (int i = 1; i <= n; i++) f[i][0] = pa[i];
  for (int j = 1; j <= m; j++)
    for (int i = 1; i <= n; i++)
      if (f[i][j - 1] != -1) f[i][j] = f[f[i][j - 1]][j - 1];
}
void dfs(int u, int cha, int hi) {
  h[u] = hi;
  for (int v : ke[u]) {
    if (v == cha) continue;
    if (h[v]) continue;
    pa[v] = u;
    dfs(v, u, hi + 1);
  }
}
int lca(int u, int v) {
  if (h[u] < h[v]) swap(u, v);
  int x = 0;
  while ((1 << x) <= h[u]) x++;
  x--;
  for (int i = x; i >= 0; i--)
    if (h[u] - h[v] >= (1 << i)) u = f[u][i];
  if (u == v) return u;
  for (int i = x; i >= 0; i--) {
    if (f[u][i] != -1 && f[u][i] != f[v][i]) {
      u = f[u][i];
      v = f[v][i];
    }
  }
  return pa[u];
}
int x, y, a, b, k, r, r1, r2, r3, r4, tmp;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  cin >> n;
  for (int i = 1; i < n; i++) {
    int u, v;
    cin >> u >> v;
    ke[u].push_back(v);
    ke[v].push_back(u);
  }
  for (int i = 1; i <= n; i++) h[i] = 0;
  h[1] = 1;
  dfs(1, -1, 1);
  khoitao();
  int q;
  cin >> q;
  while (q--) {
    cin >> a >> b >> x >> y >> k;
    r = lca(x, y);
    int d = h[x] + h[y] - 2 * h[r];
    r1 = h[x] + h[a] - 2 * h[lca(a, x)];
    r2 = h[y] + h[b] - 2 * h[lca(b, y)];
    r3 = h[x] + h[b] - 2 * h[lca(x, b)];
    r4 = h[y] + h[a] - 2 * h[lca(y, a)];
    tmp = min(r1 + r2, r3 + r4) + 1;
    int res = base;
    if ((d + k) % 2 == 0) {
      res = d;
    }
    if ((tmp + k) % 2 == 0) res = min(res, tmp);
    if (res <= k) {
      cout << "YES" << '\n';
    } else
      cout << "NO" << '\n';
  }
  return 0;
}
